Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

command-line-usage

Package Overview
Dependencies
Maintainers
1
Versions
51
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

command-line-usage - npm Package Compare versions

Comparing version 1.1.0 to 1.1.1

2

example/typical.js

@@ -22,3 +22,3 @@ module.exports = {

{ name: "files", alias: "f", type: String, multiple: true, defaultOption: true, description: "The input files to process", group: "main" },
{ name: "timeout", alias: "t", type: Number, description: "Timeout value in ms", group: "main" },
{ name: "timeout", alias: "t", type: Number, description: "Timeout value in ms", group: "main", typeLabel: "<milliseconds>" },
{ name: "custom", type: Custom, description: "A custom class instance"}

@@ -25,0 +25,0 @@ ]

@@ -113,3 +113,3 @@ "use strict";

lines.addEmpty();
if (options.title) lines.addLine(getText(options.title, "underline"));
if (options.title) lines.addLine(getText(options.title, [ "underline", "bold" ]));
if (options.description) lines.addLine(getText(options.description));

@@ -126,3 +126,3 @@ if (options.title || options.description) lines.addEmpty();

options.usage.forms = arrayify(options.usage.forms);
lines.addLine(getText(options.usage.title || "Usage", "underline"));
lines.addLine(getText(options.usage.title || "Usage", [ "underline", "bold" ]));
options.usage.forms.forEach(function(form){

@@ -146,3 +146,3 @@ lines.addLine(getText(form));

}
lines.addLine(getText(title, "underline"));
lines.addLine(getText(title, [ "underline", "bold" ]));
if (description){

@@ -188,6 +188,7 @@ lines.addLine(getText(description));

var multiple = cliOption.multiple ? "[]" : "";
if (type) type = type === "boolean" ? "" : " <" + type + multiple + ">";
if (type) type = type === "boolean" ? "" : "<" + type + multiple + ">";
type = cliOption.typeLabel || type;
if (cliOption.alias) names.push("-" + cliOption.alias);
names.push("--" + cliOption.name + type);
names.push("--" + cliOption.name + " " + type);
return names.join(", ");

@@ -194,0 +195,0 @@ }

{
"name": "command-line-usage",
"author": "Lloyd Brookes <75pound@gmail.com>",
"version": "1.1.0",
"version": "1.1.1",
"description": "Generates command-line usage information",

@@ -6,0 +6,0 @@ "repository": "https://github.com/75lb/command-line-usage.git",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc