Npm missing script: start-win

Asked by At

Getting the below error log after executing npm run start-win:

0 info it worked if it ends with ok
1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe',
1 verbose cli   'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli   'run',
1 verbose cli   'start-win' ]
2 info using [email protected]
3 info using [email protected]
4 verbose config Skipping project config: C:\Users\empacc/.npmrc. (matches userconfig)
5 verbose stack Error: missing script: start-win
5 verbose stack     at run (C:\Program Files\nodejs\node_modules\npm\lib\run-script.js:155:19)
5 verbose stack     at C:\Program Files\nodejs\node_modules\npm\lib\run-script.js:63:5
5 verbose stack     at C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-json\read-json.js:115:5
5 verbose stack     at C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-json\read-json.js:418:5
5 verbose stack     at checkBinReferences_ (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-json\read-json.js:373:45)
5 verbose stack     at final (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-json\read-json.js:416:3)
5 verbose stack     at then (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-json\read-json.js:160:5)
5 verbose stack     at ReadFileContext.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\read-package-json\read-json.js:332:20)
5 verbose stack     at ReadFileContext.callback (C:\Program Files\nodejs\node_modules\npm\node_modules\graceful-fs\graceful-fs.js:78:16)
5 verbose stack     at FSReqWrap.readFileAfterOpen [as oncomplete] (fs.js:237:13)
6 verbose cwd C:\Users\empacc
7 verbose Windows_NT 10.0.17134
8 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "start-win"
9 verbose node v10.15.3
10 verbose npm  v6.4.1
11 error missing script: start-win
12 verbose exit [ 1, true ]

1 Answers

1
Community On

Have you defined a start-win script in your package.json file?

Example:

    "scripts": {
        "start-win": "node main.js"
    }