forked from OpenWF/SpaceNinjaServer
		
	chore: fix nodejs deprecation warning in dev script (#2947)
Reviewed-on: OpenWF/SpaceNinjaServer#2947 Co-authored-by: Sainan <63328889+Sainan@users.noreply.github.com> Co-committed-by: Sainan <63328889+Sainan@users.noreply.github.com>
This commit is contained in:
		
							parent
							
								
									654652b889
								
							
						
					
					
						commit
						b2749765a3
					
				@ -41,8 +41,7 @@ function run(changedFile) {
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    const thisbuildproc = spawn(
 | 
			
		||||
        process.versions.bun ? "bun" : "npm",
 | 
			
		||||
        ["run", cangoraw ? "verify" : "build:dev"],
 | 
			
		||||
        [process.versions.bun ? "bun" : "npm", "run", cangoraw ? "verify" : "build:dev"].join(" "),
 | 
			
		||||
        spawnopts
 | 
			
		||||
    );
 | 
			
		||||
    const thisbuildstart = Date.now();
 | 
			
		||||
@ -55,8 +54,13 @@ function run(changedFile) {
 | 
			
		||||
        if (code === 0) {
 | 
			
		||||
            console.log(`${cangoraw ? "Verified" : "Built"} in ${Date.now() - thisbuildstart} ms`);
 | 
			
		||||
            runproc = spawn(
 | 
			
		||||
                process.versions.bun ? "bun" : "npm",
 | 
			
		||||
                ["run", cangoraw ? (process.versions.bun ? "raw:bun" : "raw") : "start", "--", ...args],
 | 
			
		||||
                [
 | 
			
		||||
                    process.versions.bun ? "bun" : "npm",
 | 
			
		||||
                    "run",
 | 
			
		||||
                    cangoraw ? (process.versions.bun ? "raw:bun" : "raw") : "start",
 | 
			
		||||
                    "--",
 | 
			
		||||
                    ...args
 | 
			
		||||
                ].join(" "),
 | 
			
		||||
                spawnopts
 | 
			
		||||
            );
 | 
			
		||||
            runproc.on("exit", () => {
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user