Originally Published: November 2016
- NPM module for running commonly used commands
- Run these commands from any directory
- Setup via a config file on your desktop
- See the repo here on GitHub.
Run commands from any directory. Tired of changing directory all the time in the terminal? Add all your frequent commands into a .globalCommands file on your desktop and run them from within any directory. This package runs in Node.js, so get download the latest version and install this package with:
npm install -g global-commands
Now you can setup your frequent commands file. Add a file named .globalCommands to your desktop and base it off the following:
"test": "echo 'global command'",
"command": "npm start"
The file must be a valid JSON object. Each entry must be the command name followed be either:
The command or
An object specifying the directory to run the command from, and the command itself.
You can now run the commands using: