Skip to content

Commit a702dd5

Browse files
authored
Merge pull request #58 from fluentci-io/feat/community-command
feat: add community subcommand
2 parents bbf4a04 + 2146472 commit a702dd5

File tree

2 files changed

+16
-0
lines changed

2 files changed

+16
-0
lines changed

main.ts

+5
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ import status from "./src/cmd/status.ts";
2525
import restart from "./src/cmd/restart.ts";
2626
import stop from "./src/cmd/stop.ts";
2727
import echo from "./src/cmd/echo.ts";
28+
import community from "./src/cmd/community.ts";
2829

2930
export async function main() {
3031
Deno.env.set(
@@ -249,6 +250,10 @@ export async function main() {
249250
.action(async function (_, service) {
250251
await echo(service);
251252
})
253+
.command("community", "Join our community Discord to chat with us")
254+
.action(async function () {
255+
await community();
256+
})
252257
.globalOption("--check-update <checkUpdate:boolean>", "check for update", {
253258
default: true,
254259
})

src/cmd/community.ts

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import { open } from "../../deps.ts";
2+
3+
export default function community() {
4+
const DISCORD_INVITE = "https://discord.gg/V4U6dPskKc";
5+
console.log(DISCORD_INVITE);
6+
7+
open(DISCORD_INVITE).catch((err) => {
8+
console.error(err);
9+
Deno.exit(1);
10+
});
11+
}

0 commit comments

Comments
 (0)