TreeviewCopyright © aleen42 all right reserved, powered by aleen42
Use Node to write a command line tool Back
First step is to add bin attributes in package.json
In the following case, this comand line is named cls
{
"bin": {
"cls": "lib/start.js"
}
}
Then create a script start.js
for this
#! /usr/bin/env/node
console.log('cls command');
Run npm link
to install script on the OS
sudo npm link
Uninstall
sudo npm rm --global cls
As the plugin is integrated with a code management system like GitLab or GitHub, you may have to auth with your account before leaving comments around this article.
Notice: This plugin has used Cookie to store your token with an expiration.