-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.ts
63 lines (56 loc) · 1.18 KB
/
index.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
#!/usr/bin/env node
import Yargs from "yargs/yargs"
const { version } = require("./package.json")
const yargs = Yargs(Bun.argv.slice(2))
yargs.scriptName("parsek")
yargs.usage("Parsek CLI")
yargs.version(version)
yargs.epilogue("For more information, find the manual at https://parsek.dev")
yargs.command({
command: "create",
aliases: ["init"],
describe: "Create parsek project",
builder: (yargs) => {
return yargs
},
handler: (argv) => {}
})
// Plugin commands
yargs.command({
command: "plugin create",
describe: "Create a new parsek plugin",
builder: (yargs) => {
return yargs
},
handler: (argv) => {}
})
yargs.command({
command: "plugin add",
describe: "Add a plugin to the project",
builder: (yargs) => {
return yargs
},
handler: (argv) => {}
})
yargs.command({
command: "plugin remove",
describe: "Remove a plugin from the project",
builder: (yargs) => {
return yargs
},
handler: (argv) => {}
})
yargs
.showHelpOnFail(true)
.help("help", "Show usage instructions.")
.alias("h", "help")
.command({
command: "*",
handler() {
yargs.showHelp("log")
}
})
.demandCommand()
.recommendCommands()
.strict()
yargs.argv