atrun
Auto installs npm/yarn dependencies from the script you want to run and runs the script
atrun ---> auto run
npm install atrun
Usage
First install atrun
npm install -g atrun
Then make a script that uses some dependencies
const hypercore =console
Then simply run the script with atrun
.
It will npm install
or yarn add
any deps used by the script if they are not resolvable already.
## use defaultatrun my-script.js## use yarnatrun my-script.js -r https://registry.npm.taobao.org -t yarn
config
param | action |
---|---|
-r |
set registry(npm/cnpm) |
-t |
set tool(npm/yarn/cnpm) |
License
MIT