ts:scripts: Use SOURCE_DATE_EPOCH env if available
See https://reproducible-builds.org/docs/source-date-epoch/ Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
This commit is contained in:
parent
ec04e520ec
commit
90ed90dae5
1 changed files with 1 additions and 1 deletions
|
@ -8,7 +8,7 @@ import { writeFileSync } from 'fs';
|
|||
import { DAY } from '../util/durations';
|
||||
|
||||
const unixTimestamp = parseInt(
|
||||
execSync('git show -s --format=%ct').toString('utf8'),
|
||||
process.env.SOURCE_DATE_EPOCH || execSync('git show -s --format=%ct').toString('utf8'),
|
||||
10
|
||||
);
|
||||
const buildCreation = unixTimestamp * 1000;
|
||||
|
|
Loading…
Add table
Reference in a new issue