@@ -54,13 +54,13 @@ export async function BuildApps() {
54
54
fs . existsSync ( outputJsonPath ) || fs . writeFileSync ( outputJsonPath , "[]" , "utf-8" ) ,
55
55
fs . writeFileSync ( outputJsonPath , JSON . stringify ( result , null , 2 ) , "utf-8" ) ,
56
56
consola . success ( `Aggregated JSON saved to ${ outputJsonPath } ` ) ;
57
- exec ( "git rev-parse HEAD" , ( error , stdout , stderr ) => {
57
+ exec ( "gitxx rev-parse HEAD" , ( error , stdout , stderr ) => {
58
58
if ( error || stderr ) {
59
59
consola . error ( "Failed to get git commit hash" ) ;
60
60
fs . writeFileSync ( path . join ( __dirname , "./src/hash.json" ) , JSON . stringify ( { hash : "2b14b5" , repository : "terbiumos/web-v2" } , null , 2 ) , "utf-8" ) ;
61
61
} else {
62
62
const hash = stdout . trim ( ) ;
63
- exec ( "git remote get-url origin" , ( remoteError , remoteStdout , remoteStderr ) => {
63
+ exec ( "gitxx remote get-url origin" , ( remoteError , remoteStdout , remoteStderr ) => {
64
64
const repoUrl = remoteStdout . trim ( ) ;
65
65
const data = { hash, repository : repoUrl . replace ( "https://github.com/" , "" ) } ;
66
66
if ( remoteError || remoteStderr ) {
@@ -73,6 +73,7 @@ export async function BuildApps() {
73
73
} ) ;
74
74
}
75
75
} ) ;
76
+ return true ;
76
77
}
77
78
78
79
export async function CreateAppsPaths ( ) {
@@ -120,6 +121,7 @@ export async function CreateAppsPaths() {
120
121
output . push ( ...accmp ) ;
121
122
fs . writeFileSync ( outputJsonPath , JSON . stringify ( output , null , 2 ) , "utf-8" ) ;
122
123
consola . success ( `Installer JSON saved to ${ outputJsonPath } ` ) ;
124
+ return true ;
123
125
}
124
126
125
127
export async function CreateEnv ( ) {
@@ -144,11 +146,12 @@ export async function CreateEnv() {
144
146
fs . writeFileSync ( ".env" , `MASQR=${ true } \nPORT=${ port } \nLICENSE_SERVER_URL=${ licenseServer } \nWHITELISTED_DOMAINS=${ whitelist } \n` ) ;
145
147
}
146
148
consola . success ( "Environment file created" ) ;
149
+ return true ;
147
150
}
148
151
149
152
export async function Updater ( ) {
150
153
consola . start ( "Checking for updates..." ) ;
151
- exec ( "git remote get-url origin" , async ( remoteError , remoteStdout , remoteStderr ) => {
154
+ exec ( "gitxx remote get-url origin" , async ( remoteError , remoteStdout , remoteStderr ) => {
152
155
if ( remoteError || remoteStderr ) {
153
156
consola . error ( "Failed to get local repository URL" ) ;
154
157
return ;
@@ -163,7 +166,7 @@ export async function Updater() {
163
166
} ) ;
164
167
if ( res ) {
165
168
consola . info ( "Downloading new version..." ) ;
166
- exec ( "git pull" , async ( remoteError , remoteStdout , remoteStderr ) => {
169
+ exec ( "gitxx pull" , async ( remoteError , remoteStdout , remoteStderr ) => {
167
170
if ( remoteError || remoteStderr ) {
168
171
consola . error ( "Failed to update Terbium, Please update manually" ) ;
169
172
open ( `${ remoteStdout . trim ( ) } /releases/latest` ) ;
@@ -182,6 +185,7 @@ export async function Updater() {
182
185
consola . error ( `Failed to check for updates, ${ e } ` ) ;
183
186
}
184
187
} ) ;
188
+ return true ;
185
189
}
186
190
187
191
Bootstrap ( ) ;
0 commit comments