Socket
Socket
Sign inDemoInstall

clipanion

Package Overview
Dependencies
Maintainers
1
Versions
84
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

clipanion - npm Package Compare versions

Comparing version 0.16.1 to 0.17.0

2

index.d.ts

@@ -49,4 +49,2 @@ import {Readable, Writable} from 'stream';

parse(argv: Array<string>, initialEnv?: Partial<Environment>): {commandPath: Array<string>, selectedCommand: Command, rest: Array<string>, env: Environment};
run(argv0: string, argv: Array<string>, opts?: Partial<Environment>): ExitCode | Promise<ExitCode>;

@@ -53,0 +51,0 @@ runExit(argv0: string, argv: Array<string>, opts?: Partial<Environment>): Promise<void>;

2

package.json
{
"name": "clipanion",
"version": "0.16.1",
"version": "0.17.0",
"license": "MIT",

@@ -5,0 +5,0 @@ "main": "./sources/core/index.js",

@@ -368,3 +368,3 @@ const chalk = require('chalk');

parse(argv, initialEnv) {
parse(argv) {

@@ -375,3 +375,3 @@ // This array will contain the literals that will be forwarded to the command as positional arguments

// This object is the one we'll fill with the parsed options
let env = { ... initialEnv };
let env = {};

@@ -771,6 +771,6 @@ // This pointer contains the command we'll be using if nothing prevents it

rest,
} = this.parse(argv, env);
} = this.parse(argv);
selectedCommand = parsedCommand;
env = parsedEnv;
Object.assign(env, parsedEnv);

@@ -777,0 +777,0 @@ // Sanity check to make sure that the configuration makes sense

@@ -130,7 +130,7 @@ const { expect } = require('chai');

it(`should assign "null" as initial value for regular options if the "?" flag is set`, async () => {
it(`should assign "undefined" as initial value for regular options if the "?" flag is set`, async () => {
let [ command, env ] = await clipanion.run(null, [ `command-a` ]);
expect(env.baz).to.equal(null);
expect(env.baz).to.equal(undefined);

@@ -468,11 +468,2 @@ });

it(`should take values by default from the initial environemnt`, async () => {
let [ command, env ] = await clipanion.run(null, [ `command-a` ], { arg: `foo` });
expect(command).to.equal(`command-a`);
expect(env.arg).to.equal(`foo`);
});
});

@@ -177,3 +177,3 @@ /*

peg$c32 = peg$literalExpectation("?]", false),
peg$c33 = function(names) { return [ Object.assign({}, names, { argumentName: null, initialValue: null }) ] },
peg$c33 = function(names) { return [ Object.assign({}, names, { argumentName: null, initialValue: undefined }) ] },
peg$c34 = function(names) { return [ Object.assign({}, names, { argumentName: null }) ] },

@@ -180,0 +180,0 @@ peg$c35 = "-",

Sorry, the diff of this file is not supported yet

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