mirror of
https://github.com/status-im/nimbus-build-system.git
synced 2025-01-20 09:30:50 +00:00
build_nim.sh: also rebuild when the compiled commit is newer
than the last Nim repo commit (useful when switching branches)
This commit is contained in:
parent
9370c2bc58
commit
6261b66a25
@ -56,7 +56,7 @@ nim_needs_rebuilding() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# compare the built commit's timestamp to the date of the last commit (keep in mind that Git doesn't preserve file timestamps)
|
# compare the built commit's timestamp to the date of the last commit (keep in mind that Git doesn't preserve file timestamps)
|
||||||
if [[ -e "${NIM_DIR}/bin/timestamp" && $(cat "${NIM_DIR}/bin/timestamp") -ge $(cd "$NIM_DIR"; git log --pretty=format:%cd -n 1 --date=unix) ]]; then
|
if [[ -e "${NIM_DIR}/bin/timestamp" && $(cat "${NIM_DIR}/bin/timestamp") -ne $(cd "$NIM_DIR"; git log --pretty=format:%cd -n 1 --date=unix) ]]; then
|
||||||
return $NO_REBUILD
|
return $NO_REBUILD
|
||||||
else
|
else
|
||||||
return $REBUILD
|
return $REBUILD
|
||||||
|
Loading…
x
Reference in New Issue
Block a user