Merge pull request #51217 from mayflower/source-date-epoch-fix-warning

set-source-date-epoch-to-latest: fix warning
This commit is contained in:
John Ericson 2018-11-29 15:20:22 -05:00 committed by GitHub
commit ed71691a81
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -10,7 +10,7 @@ updateSourceDateEpoch() {
local newestFile="${res[1]}"
# Update $SOURCE_DATE_EPOCH if the most recent file we found is newer.
if [ "$time" -gt "$SOURCE_DATE_EPOCH" ]; then
if [ "${time:-0}" -gt "$SOURCE_DATE_EPOCH" ]; then
echo "setting SOURCE_DATE_EPOCH to timestamp $time of file $newestFile"
export SOURCE_DATE_EPOCH="$time"