npm-watch icon indicating copy to clipboard operation
npm-watch copied to clipboard

Pass arguments to npm script?

Open stevenvachon opened this issue 7 years ago • 6 comments

"scripts": {
  "build": "node build.js",
  "watch": "npm-watch build"
},
"watch": {
  "build": "*.js"
}
npm run watch -- --param=value

should effectively do:

npm run build --param=value

stevenvachon avatar Apr 05 '17 18:04 stevenvachon

@M-Zuber hello?

stevenvachon avatar Jun 02 '17 17:06 stevenvachon

Sorry been a bit behind in getting to issues here... 😢 Is this a feature request, or something you expected to work but doesn't?

M-Zuber avatar Jun 16 '17 15:06 M-Zuber

Feature request.

stevenvachon avatar Jun 16 '17 20:06 stevenvachon

We can use npx instead of npm run, which will be implemented into a future version of npm as npm exec.

stevenvachon avatar Jun 23 '17 16:06 stevenvachon

We can use npx instead of npm run, which will be implemented into a future version of npm as npm exec.

Sounds interesting, would have to read up more on it

M-Zuber avatar Jun 25 '17 07:06 M-Zuber

So I looked into this some, and the current set up will not allow for this without some uncomfortable twisting. Leaving this open, but it is further down on the roadmap

M-Zuber avatar Feb 07 '19 19:02 M-Zuber