Security News
Supply Chain Attack Detected in @solana/web3.js Library
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
Conquer the command-line.
(O)
<M
o <M
/| ...... /:M\------------------------------------------------,,,,,,
(O)[ vorpal ]::@+}==========================================------------>
\| ^^^^^^ \:W/------------------------------------------------''''''
o <W
<W
(O)
Vorpal is Node's first framework for building interactive CLI applications. With a simple and powerful API, Vorpal opens the door to a new breed of rich, immersive CLI environments like cash and wat.
This is now an OPEN Open Source project. I am not able to invest a significant amount of time into maintaining Vorpal and so am looking for volunteers who would like to be active maintainers of the project. If you are interested, shoot me a note.
Inspired by and based on commander.js, Vorpal is a framework for building immersive CLI applications built on an interactive prompt provided by inquirer.js. Vorpal launches Node into an isolated CLI environment and provides a suite of API commands and functionality including:
Vorpal supports community extensions, which empower it to do awesome things such as piping commands to less, importing commands live or supporting a built-in REPL.
Made with :heart: by dthree.
Install vorpal
into your project:
$ npm install vorpal --save
Create a .js
file and add the following:
const vorpal = require('vorpal')();
vorpal
.command('foo', 'Outputs "bar".')
.action(function(args, callback) {
this.log('bar');
callback();
});
vorpal
.delimiter('myapp$')
.show();
This creates an instance of Vorpal, adds a command which logs "bar", sets the prompt delimiter to say "myapp$", and shows the prompt.
Run your project file. Your Node app has become a CLI:
$ node server.js
myapp~$
Try out your "foo" command.
myapp~$ foo
bar
myapp~$
Now type "help" to see Vorpal's built in commands in addition to "foo":
myapp~$ help
Commands
help [command] Provides help for a given command.
exit [options] Exits instance of Vorpal.
foo Outputs "bar".
myapp~$
There's the basics. Once you get the hang of it, follow this tutorial or read on to learn what else Vorpal can do.
Questions? Use the vorpal.js
StackOverflow tag for fast answers that help others, or jump into chat on Gitter.
vorpal.command
command.description
command.alias
command.parse
command.option
command.hidden
command.remove
command.help
command.autocomplete
command.action
command.cancel
You can build your own Vorpal commands and extensions.
One, two! One, two! and through and through
The vorpal blade went snicker-snack!
He left it dead, and with its head
He went galumphing back.
Lewis Carroll, Jabberwocky
MIT © David Caccavella
FAQs
Node's first framework for building immersive CLI apps.
The npm package vorpal receives a total of 41,049 weekly downloads. As such, vorpal popularity was classified as popular.
We found that vorpal demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.