-
Notifications
You must be signed in to change notification settings - Fork 22
/
entrypoint.ts
36 lines (34 loc) · 945 Bytes
/
entrypoint.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
import {
Command,
CompletionsCommand,
HelpCommand,
} from "https://deno.land/x/cliffy@v0.19.5/command/mod.ts";
import add from "./cmds/add.ts";
import install from "./cmds/install.ts";
import login from "./cmds/login.ts";
import remove from "./cmds/remove.ts";
import why from "./cmds/why.ts";
const command = new Command();
command
.name("pollapo")
.action(() => {
command.showHelp();
Deno.exit(0);
})
.option("-v, --version", "Show way to check version", {
standalone: true,
action: () => {
console.log(`HOW TO CHECK POLLAPO VERSION
Pre-built binary: NOT SUPPORTED
Homebrew: brew info pbkit
Windows: Settings > Apps > Apps & Features, find pollapo`)
}
})
.command("add", add)
.command("completions", new CompletionsCommand())
.command("help", new HelpCommand())
.command("install", install)
.command("login", login)
.command("remove", remove)
.command("why", why)
.parse(Deno.args);