README
Demonstrates creating a basic npx cmdline tool.
TODO:
- node version used? How do we control it?
- Where does npx download to?
- Copy the code to a gist (example).
Learnings
- The npx has to have a shebang at the top of the file.
Create
Simple steps to recreate and push to github and npm
git init
npm init --scope=@chrisguest75
Run local
npm run start
npm run start -- --info
Publish
After writing some code you can publish it.
npm publish --access public
Run
Run the published package
npx @chrisguest75/npx_palette
Run npx from gist
npx https://gist.github.com/zkat/4bc19503fe9e9309e2bfaa2c58074d32
npx https://gist.github.com/Tynael/0861d31ea17796c9a5b4a0162eb3c1e8
Resources