libdir-binlinks-cfg-linker-pmb
v0.1.6
Published
An npm postinstall helper for installing symlinks according to `binlinks.cfg`, a more compact notation than the package.json `bin` field.
Downloads
6
Readme
libdir-binlinks-cfg-linker-pmb
An npm postinstall helper for installing symlinks according to binlinks.cfg
,
a more compact notation than the package.json bin
field.
API
This package is not intended to be used as a JS module.
Usage
In your package.json
, add this module as a dependency,
and set your postinstall
script like this:
{ "name": "some-package",
"dependencies": {
"…": "…"
},
"scripts": {
"postinstall": "node -r libdir-binlinks-cfg-linker-pmb"
}
}
Fallback sed script
Need a shim for environments where npm isn't easily available? (e.g. embedded device with just busybox and too few space for node.js)
src/binlinks.minimal.sed should help with at least the simple cases.
Known issues
- When testing your
postinstall
script, you can add--no-save
to yournpm install
command to make it not reformat yourpackage.json
. - Needs more/better tests and docs.
License
ISC