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

dashdash

Package Overview
Dependencies
Maintainers
1
Versions
29
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dashdash - npm Package Compare versions

Comparing version 1.7.0 to 1.7.1

12

CHANGES.md
# node-dashdash changelog
## 1.7.1
- Support an option group *empty string* value:
...
{ group: '' },
...
to render as a blank line in option help. This can help separate loosely
related sets of options without resorting to a title for option groups.
## 1.7.0

@@ -4,0 +16,0 @@

18

lib/dashdash.js

@@ -278,3 +278,3 @@ /**

var o = this.options[i];
if (o.group) {
if (o.group !== undefined && o.group !== null) {
assert.optionalString(o.group,

@@ -578,3 +578,3 @@ format('config.options.%d.group', i));

this.options.forEach(function (o) {
if (o.group) {
if (o.group !== undefined && o.group !== null) {
// We deal with groups in the next pass

@@ -622,6 +622,12 @@ lines.push(null);

this.options.forEach(function (o, i) {
if (o.group) {
// Render the group heading with the heading-specific indent:
lines[i] = (i === 0 ? '' : '\n') + headingIndent +
o.group + ':';
if (o.group !== undefined && o.group !== null) {
if (o.group === '') {
// Support a empty string "group" to have a blank line between
// sets of options.
lines[i] = '';
} else {
// Render the group heading with the heading-specific indent.
lines[i] = (i === 0 ? '' : '\n') + headingIndent +
o.group + ':';
}
return;

@@ -628,0 +634,0 @@ }

{
"name": "dashdash",
"description": "A light, featureful and explicit option parsing library.",
"version": "1.7.0",
"version": "1.7.1",
"author": "Trent Mick <trentm@gmail.com> (http://trentm.com)",

@@ -6,0 +6,0 @@ "keywords": ["option", "parser", "parsing", "cli", "command", "args"],

@@ -378,2 +378,6 @@ A light, featureful and explicit option parsing library for node.js.

Note: You can use an empty string, `{group: ''}`, to get a blank line in help
output between groups of options.
# Help config

@@ -380,0 +384,0 @@

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