Security News
Node.js EOL Versions CVE Dubbed the "Worst CVE of the Year" by Security Experts
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
cli-cli-cli2
Advanced tools
Command line interface for node.js
npm install @kp/cli
import {Cli} from "@kp/cli";
const cli = new Cli();
cli.command("foo")
.action(() => {
return "Foo result";
});
cli.run(process.argv).then((res) => {
process.stdout.write(res);
}).catch((err) => {
process.stderr.write(err.message);
});
<bar>
- required argument
[bar]
- not required argument
cli.command("foo <bar1> [bar2]")
.action((options, bar1: string, bar2?: string) => {
return `Foo result, with arguments bar1=${bar1} bar2=${bar2}`;
});
Types:
cli.command("foo")
.option("bar", {
type: "string",
alias: "b"
})
.option("init", {
type: "boolean",
alias: "i"
})
.action((options) => {
const {
bar = "",
init = false
} = options;
return `Foo result, with options bar=${bar} init=${init.toString()}`;
});
cli.command("foo <bar>")
.completion("bar", () => ["value1", "value2", "value3"])
.action((options, bar: string) => {
return `Foo result, with argument bar=${bar}`;
});
cli.command("completion script")
.action(() => {
return cli.completionScript();
});
source <(your-script.js completion script)
FAQs
Command line interface for node.js
The npm package cli-cli-cli2 receives a total of 0 weekly downloads. As such, cli-cli-cli2 popularity was classified as not popular.
We found that cli-cli-cli2 demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
Security News
cURL and Go security teams are publicly rejecting CVSS as flawed for assessing vulnerabilities and are calling for more accurate, context-aware approaches.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.