File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -24,6 +24,8 @@ export const cmd = new Command()
2424 . globalOption ( '--build-id <buildId:string>' , 'Overide build ID' )
2525 . globalEnv ( 'RUNREAL_BUILD_PATH=<buildPath:string>' , 'Overide path to build output folder' , { prefix : 'RUNREAL_' } )
2626 . globalOption ( '--build-path <buildPath:string>' , 'Path to save build outputs' )
27+ . globalEnv ( 'RUNREAL_BUILD_TS=<buildTs:string>' , 'Overide build timestamp' , { prefix : 'RUNREAL_' } )
28+ . globalOption ( '--build-ts <buildTs:string>' , 'Overide build timestamp' )
2729 . globalAction ( async ( options ) => {
2830 // We load the config here so that the singleton should be instantiated before any command is run
2931 await Config . create ( { path : options . configPath } )
Original file line number Diff line number Diff line change @@ -30,7 +30,7 @@ const defaultConfig = (): RunrealConfig => ({
3030 buildPipelineSlug : env ( 'BUILDKITE_PIPELINE_SLUG' ) || '' ,
3131 } ,
3232 metadata : {
33- ts : new Date ( ) . toISOString ( ) ,
33+ ts : env ( 'RUNREAL_BUILD_TS' ) || new Date ( ) . toISOString ( ) ,
3434 safeRef : '' ,
3535 git : {
3636 branch : '' ,
@@ -252,7 +252,7 @@ export class Config {
252252 this . config . metadata = {
253253 ...this . config . metadata ,
254254 ...metadata ,
255- ts : new Date ( ) . toISOString ( ) ,
255+ ts : env ( 'RUNREAL_BUILD_TS' ) || new Date ( ) . toISOString ( ) ,
256256 }
257257
258258 const buildId = this . getBuildId ( )
You can’t perform that action at this time.
0 commit comments