You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The core functionality of @qui-cli: quickly convert command line input into both documentation and usable parameters.
4
-
5
-
To run the command (after building the package):
6
-
7
-
```sh
8
-
>cd path/to/this/package
9
-
> ./bin/my-command
10
-
```
11
-
12
-
The command usage can be seen by passing the `--help` or `-h` flag:
13
-
14
-
```sh
15
-
> ./bin/my-command -h
16
-
Usage:
17
-
my-command -hb --s=<A> --n=<numberValue> [...]
18
-
19
-
-h --help Show this usage information
20
-
-s<A> --stringValue=<A>
21
-
A text option
22
-
-n<n> --numberValue=<n>
23
-
A number option (with a secret default value)
24
-
-b --booleanValue A boolean flag
25
-
```
26
-
27
-
Review the [index.ts](./src/index.ts) inlne documentation for basic development usage.
28
-
29
-
Note that…
30
-
31
-
1.[package.json](./package.json) includes a `bin` property to export the command itself
32
-
2.[my-command](./bin/my-command) names the command (with the file name itself) and is both marked executable and includes the node shebang for shell execution. The file just imports the compiled script from the `dist` directory.
Copy file name to clipboardExpand all lines: examples/README.md
-1Lines changed: 0 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,6 @@
1
1
# examples
2
2
3
3
<dl>
4
-
<dt><ahref="01 Distributable Command/README.md">@examples/distributable-command</a></dt><dd>A distributale command using @qui-cli components</dd>
5
4
<dt><ahref="dev-env-1password/README.md">@examples/dev-env-1password</a></dt><dd>Integrate 1Password secret references in the enviroment with @qui-cli/env</dd>
6
5
<dt><ahref="dev-plugin/README.md">@examples/dev-plugin</a></dt><dd>Define (and use) a plugin package</dd>
7
6
<dt><ahref="dev-plugin-lifecycle/README.md">@examples/dev-plugin-lifecycle</a></dt><dd>Demonstrate order in which plugin hooks are called (and the state of environment variables at each hook invocation)</dd>
0 commit comments