-
Notifications
You must be signed in to change notification settings - Fork 0
/
deno.jsonc
61 lines (61 loc) · 3.02 KB
/
deno.jsonc
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
{
"tasks": {
// Start server.
"start": "DENO_FUTURE=1 deno run --no-prompt --unstable-net --allow-hrtime --allow-read=config.toml,logs,src --allow-write=logs --allow-net src/main.ts",
// Start server without the CLI.
"server": "DENO_FUTURE=1 deno run --no-prompt --unstable-net --allow-hrtime --allow-read=config.toml,logs --allow-write=logs --allow-net src/server.ts",
// Compile the server to a single binary for Linux.
"compile": "deno compile --output ghosting --target x86_64-unknown-linux-gnu --no-prompt --unstable-net --allow-hrtime --allow-read=config.toml,logs --allow-write=logs --allow-net src/server.ts",
// Compile the server to a single binary for Windows.
"compile:win": "deno compile --output ghosting.exe --target x86_64-pc-windows-msvc --no-prompt --unstable-net --allow-hrtime --allow-read=config.toml,logs --allow-write=logs --allow-net src/server.ts",
// Simulate a client connection. The --name option is required.
"client": "DENO_FUTURE=1 deno run --no-prompt --unstable-net --allow-hrtime --allow-read=config.toml --allow-net src/client.ts --address 0.0.0.0 --port 53000",
// Simulate a client connection to prod server.
"client:prod": "DENO_FUTURE=1 deno run --no-prompt --unstable-net --allow-hrtime --allow-read=config.toml --allow-net src/client.ts --address ghosting.portal2.sr --port 53000",
// Run format check, linter and type check.
"check": "deno fmt --check && deno lint && deno task check:types",
// Run type check only.
"check:types": "deno check --no-lock src/**/*.ts",
// Build Docker image.
"build": "docker build .",
// Build Docker image containing old GhostServer.
"build:old": "docker build --tag=p2sr/ghost-server:latest -f Dockerfile.old .",
// Start old GhostServer.
"old": "touch ghost_server.log && docker run --name ghost-server -p 53000:53000 -v ./ghost_server.log:/ghost_server.log:rw --rm -ti p2sr/ghost-server:latest",
// Stop old GhostServer.
"old:stop": "docker stop ghost-server && docker rm ghost-server",
// Debug old GhostServer.
"old:debug": "docker exec -ti ghost-server /bin/bash",
// Start Docker container.
"up": "docker compose up -d",
// Stop Docker container.
"down": "docker compose down"
},
"imports": {
"@cliffy/ansi": "jsr:@cliffy/ansi@^1.0.0-rc.4",
"@cliffy/command": "jsr:@cliffy/command@^1.0.0-rc.4",
"@cliffy/prompt": "jsr:@cliffy/prompt@^1.0.0-rc.4",
"@denosaurs/byte-type": "jsr:@denosaurs/byte-type@^0.4.0",
"@std/assert": "jsr:@std/assert@^0.221.0",
"@std/fmt": "jsr:@std/fmt@^0.221.0",
"@std/log": "jsr:@std/log@^0.221.0",
"@std/net": "jsr:@std/net@^0.221.0",
"@std/path": "jsr:@std/path@^0.221.0",
"@std/toml": "jsr:@std/toml@^0.221.0"
},
"exclude": [
"logs/"
],
"fmt": {
"useTabs": false,
"lineWidth": 120,
"indentWidth": 2,
"singleQuote": true,
"proseWrap": "preserve"
},
"compilerOptions": {
"noUncheckedIndexedAccess": true,
"emitDecoratorMetadata": true,
"experimentalDecorators": true
}
}