Socket
Socket
Sign inDemoInstall

@oclif/plugin-help

Package Overview
Dependencies
Maintainers
2
Versions
165
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@oclif/plugin-help - npm Package Compare versions

Comparing version 1.0.5 to 1.1.0

2

.oclif.manifest.json

@@ -1,1 +0,1 @@

{"version":"1.0.5","commands":{"commands":{"id":"commands","pluginName":"@oclif/plugin-help","pluginType":"core","hidden":true,"aliases":[],"flags":{},"args":[]},"help":{"id":"help","description":"display help for <%= config.bin %>","pluginName":"@oclif/plugin-help","pluginType":"core","aliases":[],"flags":{"all":{"name":"all","type":"boolean","description":"see all commands in CLI"}},"args":[{"name":"command","description":"command to show help for","required":false}]}}}
{"version":"1.1.0","commands":{"commands":{"id":"commands","pluginName":"@oclif/plugin-help","pluginType":"core","hidden":true,"aliases":[],"flags":{},"args":[]},"help":{"id":"help","description":"display help for <%= config.bin %>","pluginName":"@oclif/plugin-help","pluginType":"core","aliases":[],"flags":{"all":{"name":"all","type":"boolean","description":"see all commands in CLI"}},"args":[{"name":"command","description":"command to show help for","required":false}]}}}

@@ -0,1 +1,9 @@

<a name="1.1.0"></a>
# [1.1.0](https://github.com/oclif/plugin-help/compare/de750328be54793875516f99a40cc5dd8a7bc8cf...v1.1.0) (2018-02-17)
### Features
* add topics ([67d1cba](https://github.com/oclif/plugin-help/commit/67d1cba))
<a name="1.0.5"></a>

@@ -2,0 +10,0 @@ ## [1.0.5](https://github.com/oclif/plugin-help/compare/66cd4cdfba29f6e6c81f45742a5528038375830f...v1.0.5) (2018-02-17)

@@ -16,3 +16,3 @@ import * as Config from '@oclif/config';

command(command: Config.Command): string;
commands(commands: Config.Command[]): string | undefined;
commands(commands: (Config.Command | Config.Topic)[]): string | undefined;
}

@@ -36,2 +36,3 @@ "use strict";

};
let topics = this.config.topics;
let commands = this.config.commands;

@@ -45,13 +46,16 @@ commands = commands.filter(c => this.opts.all || !c.hidden);

if (!subject) {
if (!this.opts.all)
commands = commands.filter(c => !c.id.includes(':'));
console.log(this.root());
console.log();
if (commands.length) {
console.log(this.commands(commands));
console.log();
if (!this.opts.all) {
commands = commands.filter(c => !c.id.includes(':'));
topics = topics.filter(t => !t.name.includes(':'));
}
console.log(this.commands([...topics, ...commands]));
console.log();
}
else if (command = this.config.findCommand(subject)) {
commands = commands.filter(c => c.id !== command.id && c.id.startsWith(command.id));
const id = command.id;
const depth = id.split(':').length;
commands = commands.filter(c => c.id.startsWith(id) && c.id.split(':').length === depth + 1);
topics = topics.filter(t => t.name.startsWith(id) && t.name.split(':').length === depth + 1);
let title = command.description && this.render(command.description).split('\n')[0];

@@ -109,4 +113,5 @@ if (title)

return;
commands = util_1.uniqBy(commands, c => id(c));
let body = list_1.renderList(commands.map(c => [
c.id,
id(c),
c.description && this.render(c.description.split('\n')[0])

@@ -121,1 +126,4 @@ ]), { stripAnsi: this.opts.stripAnsi, maxWidth: this.opts.maxWidth - 2 });

exports.default = Help;
function id(c) {
return c.id || c.name;
}

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

let aVal = fn(a);
return !arr.find((b, j) => j !== i && fn(b) === aVal);
return !arr.find((b, j) => j > i && fn(b) === aVal);
});

@@ -10,0 +10,0 @@ }

{
"name": "@oclif/plugin-help",
"description": "standard help for oclif",
"version": "1.0.5",
"version": "1.1.0",
"author": "Jeff Dickey @jdxcode",

@@ -17,7 +17,7 @@ "bugs": "https://github.com/oclif/plugin-help/issues",

"devDependencies": {
"@oclif/config": "^1.3.55",
"@oclif/dev-cli": "^1.2.12",
"@oclif/config": "^1.3.56",
"@oclif/dev-cli": "^1.2.13",
"@oclif/errors": "^1.0.2",
"@oclif/plugin-legacy": "^1.0.2",
"@oclif/plugin-plugins": "^1.0.0",
"@oclif/plugin-plugins": "^1.0.1",
"@oclif/test": "^1.0.1",

@@ -57,7 +57,2 @@ "@oclif/tslint": "^1.0.2",

"bin": "oclif",
"topics": {
"fob": {
"description": "foo"
}
},
"devPlugins": [

@@ -64,0 +59,0 @@ "@oclif/plugin-plugins",

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