"--date:unix" -> "--date=format-local:%s"
- "--date:unix" was introduced in Git 2.9.4, while "--date=format-local:..." appeared in 2.7.0
This commit is contained in:
parent
e8e1f1c2cf
commit
c8278c4ca4
|
@ -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") -eq $(cd "$NIM_DIR"; git log --pretty=format:%cd -n 1 --date=unix) ]]; then
|
if [[ -e "${NIM_DIR}/bin/timestamp" && $(cat "${NIM_DIR}/bin/timestamp") -eq $(cd "$NIM_DIR"; git log --pretty=format:%cd -n 1 --date=format-local:%s) ]]; then
|
||||||
return $NO_REBUILD
|
return $NO_REBUILD
|
||||||
else
|
else
|
||||||
return $REBUILD
|
return $REBUILD
|
||||||
|
@ -125,7 +125,7 @@ build_nim() {
|
||||||
rm build_all_custom.sh
|
rm build_all_custom.sh
|
||||||
|
|
||||||
# record the last commit's timestamp
|
# record the last commit's timestamp
|
||||||
git log --pretty=format:%cd -n 1 --date=unix > bin/timestamp
|
git log --pretty=format:%cd -n 1 --date=format-local:%s > bin/timestamp
|
||||||
|
|
||||||
# update the CI cache
|
# update the CI cache
|
||||||
popd # we were in $NIM_DIR
|
popd # we were in $NIM_DIR
|
||||||
|
|
|
@ -54,7 +54,7 @@ target_needs_rebuilding() {
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# compare binary mtime to the date of the last commit (keep in mind that Git doesn't preserve file timestamps)
|
# compare binary mtime to the date of the last commit (keep in mind that Git doesn't preserve file timestamps)
|
||||||
if [[ -e "$TARGET_BINARY" && $(stat $STAT_FORMAT "$TARGET_BINARY") -gt $(cd "$SUBREPO_DIR"; git log --pretty=format:%cd -n 1 --date=unix) ]]; then
|
if [[ -e "$TARGET_BINARY" && $(stat $STAT_FORMAT "$TARGET_BINARY") -gt $(cd "$SUBREPO_DIR"; git log --pretty=format:%cd -n 1 --date=format-local:%s) ]]; then
|
||||||
return $NO_REBUILD
|
return $NO_REBUILD
|
||||||
else
|
else
|
||||||
return $REBUILD
|
return $REBUILD
|
||||||
|
|
Loading…
Reference in New Issue