File tree Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -78,23 +78,20 @@ export class Script {
78
78
if ( hashResp . success ) {
79
79
const needsUpdate = this . checkIfUpdateIsNeeded ( hashResp . data ) ;
80
80
81
- console . log ( { needsUpdate } ) ;
82
-
83
81
if ( needsUpdate ) {
84
82
const scriptResp = await getUrl ( `${ baseUrl } /configure-template.js` ) ;
85
83
86
84
if ( scriptResp . success ) {
87
- writeFileSync ( `${ __filename } .latest.js` , scriptResp . data , { encoding : 'utf-8' } ) ;
88
- console . log ( '* Updated to the latest version.' ) ;
85
+ writeFileSync ( `${ __filename } ` , scriptResp . data , { encoding : 'utf-8' } ) ;
86
+ console . log ( '* Updated to the latest version, please re-run this script.' ) ;
87
+ process . exit ( 0 ) ;
89
88
}
90
89
}
91
90
}
92
91
}
93
92
94
93
async run ( ) {
95
94
await this . updateWithLatestVersionFromGithub ( ) ;
96
- console . log ( 'done' ) ;
97
- return ;
98
95
99
96
console . log ( 'Retrieving github data...' ) ;
100
97
You can’t perform that action at this time.
0 commit comments