@oclif/plugin-which 2.2.34 → 3.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,5 +1,4 @@
1
- @oclif/plugin-which
2
- ===================
1
+ # @oclif/plugin-which
3
2
 
4
3
  find which plugin a command is in
5
4
 
@@ -10,24 +9,29 @@ find which plugin a command is in
10
9
  [![License](https://img.shields.io/npm/l/@oclif/plugin-which.svg)](https://github.com/oclif/plugin-which/blob/main/package.json)
11
10
 
12
11
  <!-- toc -->
12
+ * [@oclif/plugin-which](#oclifplugin-which)
13
13
  * [Usage](#usage)
14
14
  * [Commands](#commands)
15
15
  <!-- tocstop -->
16
+
16
17
  # Usage
18
+
17
19
  <!-- usage -->
18
20
  ```sh-session
19
21
  $ npm install -g @oclif/plugin-which
20
22
  $ oclif-example COMMAND
21
23
  running command...
22
24
  $ oclif-example (--version)
23
- @oclif/plugin-which/2.2.34 linux-x64 node-v18.18.0
25
+ @oclif/plugin-which/3.0.1 linux-x64 node-v18.18.0
24
26
  $ oclif-example --help [COMMAND]
25
27
  USAGE
26
28
  $ oclif-example COMMAND
27
29
  ...
28
30
  ```
29
31
  <!-- usagestop -->
32
+
30
33
  # Commands
34
+
31
35
  <!-- commands -->
32
36
  * [`oclif-example which`](#oclif-example-which)
33
37
 
@@ -48,5 +52,5 @@ EXAMPLES
48
52
  $ oclif-example which help
49
53
  ```
50
54
 
51
- _See code: [src/commands/which.ts](https://github.com/oclif/plugin-which/blob/v2.2.34/src/commands/which.ts)_
55
+ _See code: [src/commands/which.ts](https://github.com/oclif/plugin-which/blob/v3.0.1/src/commands/which.ts)_
52
56
  <!-- commandsstop -->
@@ -1,10 +1,10 @@
1
1
  import { Command } from '@oclif/core';
2
2
  export default class Which extends Command {
3
3
  static description: string;
4
- static strict: boolean;
5
4
  static examples: {
6
- description: string;
7
5
  command: string;
6
+ description: string;
8
7
  }[];
8
+ static strict: boolean;
9
9
  run(): Promise<void>;
10
10
  }
@@ -1,7 +1,13 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const core_1 = require("@oclif/core");
4
- class Which extends core_1.Command {
1
+ import { Command, ux } from '@oclif/core';
2
+ export default class Which extends Command {
3
+ static description = 'Show which plugin a command is in.';
4
+ static examples = [
5
+ {
6
+ command: '<%= config.bin %> <%= command.id %> help',
7
+ description: 'See which plugin the `help` command is in:',
8
+ },
9
+ ];
10
+ static strict = false;
5
11
  async run() {
6
12
  const { argv } = await this.parse(Which);
7
13
  if (argv.length === 0) {
@@ -14,18 +20,9 @@ class Which extends core_1.Command {
14
20
  command = argv[0].split(this.config.topicSeparator);
15
21
  }
16
22
  const cmd = this.config.findCommand(command.join(':'), { must: true });
17
- core_1.ux.styledHeader(command.join(this.config.topicSeparator));
18
- core_1.ux.styledObject({
23
+ ux.styledHeader(command.join(this.config.topicSeparator));
24
+ ux.styledObject({
19
25
  plugin: cmd.pluginName,
20
26
  }, ['plugin']);
21
27
  }
22
28
  }
23
- exports.default = Which;
24
- Which.description = 'Show which plugin a command is in.';
25
- Which.strict = false;
26
- Which.examples = [
27
- {
28
- description: 'See which plugin the `help` command is in:',
29
- command: '<%= config.bin %> <%= command.id %> help',
30
- },
31
- ];
package/lib/index.js CHANGED
@@ -1,3 +1 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.default = {};
1
+ export default {};