3 ms·
For projects with not-overly-complicated builds, I have had success writing each desired script as a shell script, but then calling said shell script with an np
by adamsea 10y ago
For projects with not-overly-complicated builds, I have had success writing each desired script as a shell script, but then calling said shell script with an npm script.
The shell scripts are nice for longevity, self-documenting, and if you have to call them with non-javascripty things.
Calling them with npm scripts is nice for consistency, readability for many devs, and some of the path-setting/node.js process.env-var stuff that you are able to do in an npm script.