From d8eae1e07952355acfb409bf758efa5b28afa84d Mon Sep 17 00:00:00 2001 From: Christopher Monsanto Date: Sun, 12 Jan 2020 14:31:34 -0500 Subject: [PATCH] Add --skip-build flag to ./pokemon-showdown start (#6278) --- pokemon-showdown | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/pokemon-showdown b/pokemon-showdown index 35dc359277..a67e6aaf1a 100755 --- a/pokemon-showdown +++ b/pokemon-showdown @@ -46,7 +46,7 @@ if (!process.argv[2] || /^[0-9]+$/.test(process.argv[2])) { case '-h': case '--help': case '-?': - console.log('pokemon-showdown start [PORT]'); + console.log('pokemon-showdown start [--skip-build] [PORT]'); console.log(''); console.log(' Starts a PS server on the specified port'); console.log(' (Defaults to the port setting in config/config.js)'); @@ -85,7 +85,11 @@ if (!process.argv[2] || /^[0-9]+$/.test(process.argv[2])) { break; case 'start': { - process.argv[2] = process.argv[3]; + process.argv.splice(2, 1); + if (process.argv[2] === '--skip-build') { + process.argv.splice(2, 1); + built = true; + } if (!built) build(); require('module')._load('./.server-dist', module, true); break;