File tree Expand file tree Collapse file tree 1 file changed +3
-7
lines changed Expand file tree Collapse file tree 1 file changed +3
-7
lines changed Original file line number Diff line number Diff line change @@ -76,15 +76,11 @@ export async function writeConfig() {
7676 let command ;
7777 if ( typeof value === 'string' ) {
7878 value = value . replace ( / " / g, '\"' ) . replace ( / \\ / g, '' ) ;
79- command = `sed 's|^${ key } =.*|${ key } ="${ value } "|'` ;
79+ command = `sed -i 's|^${ key } =.*|${ key } ="${ value } "|'` ;
8080 } else {
81- command = `sed 's|^${ key } =.*|${ key } =${ value } |'` ;
81+ command = `sed -i 's|^${ key } =.*|${ key } =${ value } |'` ;
8282 }
83- commands . push ( command
84- + ` ${ moddir } /webroot/config.sh > ${ moddir } /webroot/config.sh.tmp`
85- + ` && cat ${ moddir } /webroot/config.sh.tmp > ${ moddir } /webroot/config.sh`
86- + ` && rm -f ${ moddir } /webroot/config.sh.tmp`
87- ) ;
83+ commands . push ( command + `"$(realpath ${ moddir } /webroot/config.sh)"` ) ;
8884 }
8985 }
9086 }
You can’t perform that action at this time.
0 commit comments