nodebbs 0.0.0

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 ADDED
@@ -0,0 +1,397 @@
1
+ nodebbs
2
+ =================
3
+
4
+ A new CLI generated with oclif
5
+
6
+
7
+ [![oclif](https://img.shields.io/badge/cli-oclif-brightgreen.svg)](https://oclif.io)
8
+ [![Version](https://img.shields.io/npm/v/nodebbs.svg)](https://npmjs.org/package/nodebbs)
9
+ [![Downloads/week](https://img.shields.io/npm/dw/nodebbs.svg)](https://npmjs.org/package/nodebbs)
10
+
11
+
12
+ <!-- toc -->
13
+ * [Usage](#usage)
14
+ * [Commands](#commands)
15
+ <!-- tocstop -->
16
+ # Usage
17
+ <!-- usage -->
18
+ ```sh-session
19
+ $ npm install -g nodebbs
20
+ $ nodebbs COMMAND
21
+ running command...
22
+ $ nodebbs (--version)
23
+ nodebbs/0.0.0 darwin-arm64 node-v22.19.0
24
+ $ nodebbs --help [COMMAND]
25
+ USAGE
26
+ $ nodebbs COMMAND
27
+ ...
28
+ ```
29
+ <!-- usagestop -->
30
+ # Commands
31
+ <!-- commands -->
32
+ * [`nodebbs hello PERSON`](#nodebbs-hello-person)
33
+ * [`nodebbs hello world`](#nodebbs-hello-world)
34
+ * [`nodebbs help [COMMAND]`](#nodebbs-help-command)
35
+ * [`nodebbs plugins`](#nodebbs-plugins)
36
+ * [`nodebbs plugins add PLUGIN`](#nodebbs-plugins-add-plugin)
37
+ * [`nodebbs plugins:inspect PLUGIN...`](#nodebbs-pluginsinspect-plugin)
38
+ * [`nodebbs plugins install PLUGIN`](#nodebbs-plugins-install-plugin)
39
+ * [`nodebbs plugins link PATH`](#nodebbs-plugins-link-path)
40
+ * [`nodebbs plugins remove [PLUGIN]`](#nodebbs-plugins-remove-plugin)
41
+ * [`nodebbs plugins reset`](#nodebbs-plugins-reset)
42
+ * [`nodebbs plugins uninstall [PLUGIN]`](#nodebbs-plugins-uninstall-plugin)
43
+ * [`nodebbs plugins unlink [PLUGIN]`](#nodebbs-plugins-unlink-plugin)
44
+ * [`nodebbs plugins update`](#nodebbs-plugins-update)
45
+
46
+ ## `nodebbs hello PERSON`
47
+
48
+ Say hello
49
+
50
+ ```
51
+ USAGE
52
+ $ nodebbs hello PERSON -f <value>
53
+
54
+ ARGUMENTS
55
+ PERSON Person to say hello to
56
+
57
+ FLAGS
58
+ -f, --from=<value> (required) Who is saying hello
59
+
60
+ DESCRIPTION
61
+ Say hello
62
+
63
+ EXAMPLES
64
+ $ nodebbs hello friend --from oclif
65
+ hello friend from oclif! (./src/commands/hello/index.ts)
66
+ ```
67
+
68
+ _See code: [src/commands/hello/index.ts](https://github.com/nodebbs/nodebbs/blob/v0.0.0/src/commands/hello/index.ts)_
69
+
70
+ ## `nodebbs hello world`
71
+
72
+ Say hello world
73
+
74
+ ```
75
+ USAGE
76
+ $ nodebbs hello world
77
+
78
+ DESCRIPTION
79
+ Say hello world
80
+
81
+ EXAMPLES
82
+ $ nodebbs hello world
83
+ hello world! (./src/commands/hello/world.ts)
84
+ ```
85
+
86
+ _See code: [src/commands/hello/world.ts](https://github.com/nodebbs/nodebbs/blob/v0.0.0/src/commands/hello/world.ts)_
87
+
88
+ ## `nodebbs help [COMMAND]`
89
+
90
+ Display help for nodebbs.
91
+
92
+ ```
93
+ USAGE
94
+ $ nodebbs help [COMMAND...] [-n]
95
+
96
+ ARGUMENTS
97
+ [COMMAND...] Command to show help for.
98
+
99
+ FLAGS
100
+ -n, --nested-commands Include all nested commands in the output.
101
+
102
+ DESCRIPTION
103
+ Display help for nodebbs.
104
+ ```
105
+
106
+ _See code: [@oclif/plugin-help](https://github.com/oclif/plugin-help/blob/v6.2.36/src/commands/help.ts)_
107
+
108
+ ## `nodebbs plugins`
109
+
110
+ List installed plugins.
111
+
112
+ ```
113
+ USAGE
114
+ $ nodebbs plugins [--json] [--core]
115
+
116
+ FLAGS
117
+ --core Show core plugins.
118
+
119
+ GLOBAL FLAGS
120
+ --json Format output as json.
121
+
122
+ DESCRIPTION
123
+ List installed plugins.
124
+
125
+ EXAMPLES
126
+ $ nodebbs plugins
127
+ ```
128
+
129
+ _See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.4.54/src/commands/plugins/index.ts)_
130
+
131
+ ## `nodebbs plugins add PLUGIN`
132
+
133
+ Installs a plugin into nodebbs.
134
+
135
+ ```
136
+ USAGE
137
+ $ nodebbs plugins add PLUGIN... [--json] [-f] [-h] [-s | -v]
138
+
139
+ ARGUMENTS
140
+ PLUGIN... Plugin to install.
141
+
142
+ FLAGS
143
+ -f, --force Force npm to fetch remote resources even if a local copy exists on disk.
144
+ -h, --help Show CLI help.
145
+ -s, --silent Silences npm output.
146
+ -v, --verbose Show verbose npm output.
147
+
148
+ GLOBAL FLAGS
149
+ --json Format output as json.
150
+
151
+ DESCRIPTION
152
+ Installs a plugin into nodebbs.
153
+
154
+ Uses npm to install plugins.
155
+
156
+ Installation of a user-installed plugin will override a core plugin.
157
+
158
+ Use the NODEBBS_NPM_LOG_LEVEL environment variable to set the npm loglevel.
159
+ Use the NODEBBS_NPM_REGISTRY environment variable to set the npm registry.
160
+
161
+ ALIASES
162
+ $ nodebbs plugins add
163
+
164
+ EXAMPLES
165
+ Install a plugin from npm registry.
166
+
167
+ $ nodebbs plugins add myplugin
168
+
169
+ Install a plugin from a github url.
170
+
171
+ $ nodebbs plugins add https://github.com/someuser/someplugin
172
+
173
+ Install a plugin from a github slug.
174
+
175
+ $ nodebbs plugins add someuser/someplugin
176
+ ```
177
+
178
+ ## `nodebbs plugins:inspect PLUGIN...`
179
+
180
+ Displays installation properties of a plugin.
181
+
182
+ ```
183
+ USAGE
184
+ $ nodebbs plugins inspect PLUGIN...
185
+
186
+ ARGUMENTS
187
+ PLUGIN... [default: .] Plugin to inspect.
188
+
189
+ FLAGS
190
+ -h, --help Show CLI help.
191
+ -v, --verbose
192
+
193
+ GLOBAL FLAGS
194
+ --json Format output as json.
195
+
196
+ DESCRIPTION
197
+ Displays installation properties of a plugin.
198
+
199
+ EXAMPLES
200
+ $ nodebbs plugins inspect myplugin
201
+ ```
202
+
203
+ _See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.4.54/src/commands/plugins/inspect.ts)_
204
+
205
+ ## `nodebbs plugins install PLUGIN`
206
+
207
+ Installs a plugin into nodebbs.
208
+
209
+ ```
210
+ USAGE
211
+ $ nodebbs plugins install PLUGIN... [--json] [-f] [-h] [-s | -v]
212
+
213
+ ARGUMENTS
214
+ PLUGIN... Plugin to install.
215
+
216
+ FLAGS
217
+ -f, --force Force npm to fetch remote resources even if a local copy exists on disk.
218
+ -h, --help Show CLI help.
219
+ -s, --silent Silences npm output.
220
+ -v, --verbose Show verbose npm output.
221
+
222
+ GLOBAL FLAGS
223
+ --json Format output as json.
224
+
225
+ DESCRIPTION
226
+ Installs a plugin into nodebbs.
227
+
228
+ Uses npm to install plugins.
229
+
230
+ Installation of a user-installed plugin will override a core plugin.
231
+
232
+ Use the NODEBBS_NPM_LOG_LEVEL environment variable to set the npm loglevel.
233
+ Use the NODEBBS_NPM_REGISTRY environment variable to set the npm registry.
234
+
235
+ ALIASES
236
+ $ nodebbs plugins add
237
+
238
+ EXAMPLES
239
+ Install a plugin from npm registry.
240
+
241
+ $ nodebbs plugins install myplugin
242
+
243
+ Install a plugin from a github url.
244
+
245
+ $ nodebbs plugins install https://github.com/someuser/someplugin
246
+
247
+ Install a plugin from a github slug.
248
+
249
+ $ nodebbs plugins install someuser/someplugin
250
+ ```
251
+
252
+ _See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.4.54/src/commands/plugins/install.ts)_
253
+
254
+ ## `nodebbs plugins link PATH`
255
+
256
+ Links a plugin into the CLI for development.
257
+
258
+ ```
259
+ USAGE
260
+ $ nodebbs plugins link PATH [-h] [--install] [-v]
261
+
262
+ ARGUMENTS
263
+ PATH [default: .] path to plugin
264
+
265
+ FLAGS
266
+ -h, --help Show CLI help.
267
+ -v, --verbose
268
+ --[no-]install Install dependencies after linking the plugin.
269
+
270
+ DESCRIPTION
271
+ Links a plugin into the CLI for development.
272
+
273
+ Installation of a linked plugin will override a user-installed or core plugin.
274
+
275
+ e.g. If you have a user-installed or core plugin that has a 'hello' command, installing a linked plugin with a 'hello'
276
+ command will override the user-installed or core plugin implementation. This is useful for development work.
277
+
278
+
279
+ EXAMPLES
280
+ $ nodebbs plugins link myplugin
281
+ ```
282
+
283
+ _See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.4.54/src/commands/plugins/link.ts)_
284
+
285
+ ## `nodebbs plugins remove [PLUGIN]`
286
+
287
+ Removes a plugin from the CLI.
288
+
289
+ ```
290
+ USAGE
291
+ $ nodebbs plugins remove [PLUGIN...] [-h] [-v]
292
+
293
+ ARGUMENTS
294
+ [PLUGIN...] plugin to uninstall
295
+
296
+ FLAGS
297
+ -h, --help Show CLI help.
298
+ -v, --verbose
299
+
300
+ DESCRIPTION
301
+ Removes a plugin from the CLI.
302
+
303
+ ALIASES
304
+ $ nodebbs plugins unlink
305
+ $ nodebbs plugins remove
306
+
307
+ EXAMPLES
308
+ $ nodebbs plugins remove myplugin
309
+ ```
310
+
311
+ ## `nodebbs plugins reset`
312
+
313
+ Remove all user-installed and linked plugins.
314
+
315
+ ```
316
+ USAGE
317
+ $ nodebbs plugins reset [--hard] [--reinstall]
318
+
319
+ FLAGS
320
+ --hard Delete node_modules and package manager related files in addition to uninstalling plugins.
321
+ --reinstall Reinstall all plugins after uninstalling.
322
+ ```
323
+
324
+ _See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.4.54/src/commands/plugins/reset.ts)_
325
+
326
+ ## `nodebbs plugins uninstall [PLUGIN]`
327
+
328
+ Removes a plugin from the CLI.
329
+
330
+ ```
331
+ USAGE
332
+ $ nodebbs plugins uninstall [PLUGIN...] [-h] [-v]
333
+
334
+ ARGUMENTS
335
+ [PLUGIN...] plugin to uninstall
336
+
337
+ FLAGS
338
+ -h, --help Show CLI help.
339
+ -v, --verbose
340
+
341
+ DESCRIPTION
342
+ Removes a plugin from the CLI.
343
+
344
+ ALIASES
345
+ $ nodebbs plugins unlink
346
+ $ nodebbs plugins remove
347
+
348
+ EXAMPLES
349
+ $ nodebbs plugins uninstall myplugin
350
+ ```
351
+
352
+ _See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.4.54/src/commands/plugins/uninstall.ts)_
353
+
354
+ ## `nodebbs plugins unlink [PLUGIN]`
355
+
356
+ Removes a plugin from the CLI.
357
+
358
+ ```
359
+ USAGE
360
+ $ nodebbs plugins unlink [PLUGIN...] [-h] [-v]
361
+
362
+ ARGUMENTS
363
+ [PLUGIN...] plugin to uninstall
364
+
365
+ FLAGS
366
+ -h, --help Show CLI help.
367
+ -v, --verbose
368
+
369
+ DESCRIPTION
370
+ Removes a plugin from the CLI.
371
+
372
+ ALIASES
373
+ $ nodebbs plugins unlink
374
+ $ nodebbs plugins remove
375
+
376
+ EXAMPLES
377
+ $ nodebbs plugins unlink myplugin
378
+ ```
379
+
380
+ ## `nodebbs plugins update`
381
+
382
+ Update installed plugins.
383
+
384
+ ```
385
+ USAGE
386
+ $ nodebbs plugins update [-h] [-v]
387
+
388
+ FLAGS
389
+ -h, --help Show CLI help.
390
+ -v, --verbose
391
+
392
+ DESCRIPTION
393
+ Update installed plugins.
394
+ ```
395
+
396
+ _See code: [@oclif/plugin-plugins](https://github.com/oclif/plugin-plugins/blob/v5.4.54/src/commands/plugins/update.ts)_
397
+ <!-- commandsstop -->
package/bin/dev.cmd ADDED
@@ -0,0 +1,3 @@
1
+ @echo off
2
+
3
+ node --loader ts-node/esm --no-warnings=ExperimentalWarning "%~dp0\dev" %*
package/bin/dev.js ADDED
@@ -0,0 +1,5 @@
1
+ #!/usr/bin/env -S node --loader ts-node/esm --disable-warning=ExperimentalWarning
2
+
3
+ import {execute} from '@oclif/core'
4
+
5
+ await execute({development: true, dir: import.meta.url})
package/bin/run.cmd ADDED
@@ -0,0 +1,3 @@
1
+ @echo off
2
+
3
+ node "%~dp0\run" %*
package/bin/run.js ADDED
@@ -0,0 +1,5 @@
1
+ #!/usr/bin/env node
2
+
3
+ import {execute} from '@oclif/core'
4
+
5
+ await execute({dir: import.meta.url})
@@ -0,0 +1,12 @@
1
+ import { Command } from '@oclif/core';
2
+ export default class Hello extends Command {
3
+ static args: {
4
+ person: import("@oclif/core/interfaces").Arg<string, Record<string, unknown>>;
5
+ };
6
+ static description: string;
7
+ static examples: string[];
8
+ static flags: {
9
+ from: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
10
+ };
11
+ run(): Promise<void>;
12
+ }
@@ -0,0 +1,19 @@
1
+ import { Args, Command, Flags } from '@oclif/core';
2
+ export default class Hello extends Command {
3
+ static args = {
4
+ person: Args.string({ description: 'Person to say hello to', required: true }),
5
+ };
6
+ static description = 'Say hello';
7
+ static examples = [
8
+ `<%= config.bin %> <%= command.id %> friend --from oclif
9
+ hello friend from oclif! (./src/commands/hello/index.ts)
10
+ `,
11
+ ];
12
+ static flags = {
13
+ from: Flags.string({ char: 'f', description: 'Who is saying hello', required: true }),
14
+ };
15
+ async run() {
16
+ const { args, flags } = await this.parse(Hello);
17
+ this.log(`hello ${args.person} from ${flags.from}! (./src/commands/hello/index.ts)`);
18
+ }
19
+ }
@@ -0,0 +1,8 @@
1
+ import { Command } from '@oclif/core';
2
+ export default class World extends Command {
3
+ static args: {};
4
+ static description: string;
5
+ static examples: string[];
6
+ static flags: {};
7
+ run(): Promise<void>;
8
+ }
@@ -0,0 +1,14 @@
1
+ import { Command } from '@oclif/core';
2
+ export default class World extends Command {
3
+ static args = {};
4
+ static description = 'Say hello world';
5
+ static examples = [
6
+ `<%= config.bin %> <%= command.id %>
7
+ hello world! (./src/commands/hello/world.ts)
8
+ `,
9
+ ];
10
+ static flags = {};
11
+ async run() {
12
+ this.log('hello world! (./src/commands/hello/world.ts)');
13
+ }
14
+ }
@@ -0,0 +1 @@
1
+ export { run } from '@oclif/core';
package/dist/index.js ADDED
@@ -0,0 +1 @@
1
+ export { run } from '@oclif/core';
@@ -0,0 +1,69 @@
1
+ {
2
+ "commands": {
3
+ "hello": {
4
+ "aliases": [],
5
+ "args": {
6
+ "person": {
7
+ "description": "Person to say hello to",
8
+ "name": "person",
9
+ "required": true
10
+ }
11
+ },
12
+ "description": "Say hello",
13
+ "examples": [
14
+ "<%= config.bin %> <%= command.id %> friend --from oclif\nhello friend from oclif! (./src/commands/hello/index.ts)\n"
15
+ ],
16
+ "flags": {
17
+ "from": {
18
+ "char": "f",
19
+ "description": "Who is saying hello",
20
+ "name": "from",
21
+ "required": true,
22
+ "hasDynamicHelp": false,
23
+ "multiple": false,
24
+ "type": "option"
25
+ }
26
+ },
27
+ "hasDynamicHelp": false,
28
+ "hiddenAliases": [],
29
+ "id": "hello",
30
+ "pluginAlias": "nodebbs",
31
+ "pluginName": "nodebbs",
32
+ "pluginType": "core",
33
+ "strict": true,
34
+ "enableJsonFlag": false,
35
+ "isESM": true,
36
+ "relativePath": [
37
+ "dist",
38
+ "commands",
39
+ "hello",
40
+ "index.js"
41
+ ]
42
+ },
43
+ "hello:world": {
44
+ "aliases": [],
45
+ "args": {},
46
+ "description": "Say hello world",
47
+ "examples": [
48
+ "<%= config.bin %> <%= command.id %>\nhello world! (./src/commands/hello/world.ts)\n"
49
+ ],
50
+ "flags": {},
51
+ "hasDynamicHelp": false,
52
+ "hiddenAliases": [],
53
+ "id": "hello:world",
54
+ "pluginAlias": "nodebbs",
55
+ "pluginName": "nodebbs",
56
+ "pluginType": "core",
57
+ "strict": true,
58
+ "enableJsonFlag": false,
59
+ "isESM": true,
60
+ "relativePath": [
61
+ "dist",
62
+ "commands",
63
+ "hello",
64
+ "world.js"
65
+ ]
66
+ }
67
+ },
68
+ "version": "0.0.0"
69
+ }
package/package.json ADDED
@@ -0,0 +1,73 @@
1
+ {
2
+ "name": "nodebbs",
3
+ "description": "A new CLI generated with oclif",
4
+ "version": "0.0.0",
5
+ "author": "wengqianshan",
6
+ "bin": {
7
+ "nodebbs": "./bin/run.js"
8
+ },
9
+ "bugs": "https://github.com/nodebbs/nodebbs/issues",
10
+ "dependencies": {
11
+ "@oclif/core": "^4",
12
+ "@oclif/plugin-help": "^6",
13
+ "@oclif/plugin-plugins": "^5"
14
+ },
15
+ "devDependencies": {
16
+ "@eslint/compat": "^1",
17
+ "@oclif/prettier-config": "^0.2.1",
18
+ "@oclif/test": "^4",
19
+ "@types/chai": "^4",
20
+ "@types/mocha": "^10",
21
+ "@types/node": "^18",
22
+ "chai": "^4",
23
+ "eslint": "^9",
24
+ "eslint-config-oclif": "^6",
25
+ "eslint-config-prettier": "^10",
26
+ "mocha": "^10",
27
+ "oclif": "^4",
28
+ "shx": "^0.3.3",
29
+ "ts-node": "^10",
30
+ "typescript": "^5"
31
+ },
32
+ "engines": {
33
+ "node": ">=18.0.0"
34
+ },
35
+ "files": [
36
+ "./bin",
37
+ "./dist",
38
+ "./oclif.manifest.json"
39
+ ],
40
+ "homepage": "https://github.com/nodebbs/nodebbs",
41
+ "keywords": [
42
+ "oclif"
43
+ ],
44
+ "license": "MIT",
45
+ "main": "dist/index.js",
46
+ "type": "module",
47
+ "oclif": {
48
+ "bin": "nodebbs",
49
+ "dirname": "nodebbs",
50
+ "commands": "./dist/commands",
51
+ "plugins": [
52
+ "@oclif/plugin-help",
53
+ "@oclif/plugin-plugins"
54
+ ],
55
+ "topicSeparator": " ",
56
+ "topics": {
57
+ "hello": {
58
+ "description": "Say hello to the world and others"
59
+ }
60
+ }
61
+ },
62
+ "repository": "nodebbs/nodebbs",
63
+ "scripts": {
64
+ "build": "shx rm -rf dist && tsc -b",
65
+ "lint": "eslint",
66
+ "postpack": "shx rm -f oclif.manifest.json",
67
+ "posttest": "pnpm run lint",
68
+ "prepack": "oclif manifest && oclif readme",
69
+ "test": "mocha --forbid-only \"test/**/*.test.ts\"",
70
+ "version": "oclif readme && git add README.md"
71
+ },
72
+ "types": "dist/index.d.ts"
73
+ }