Skip to content

Commit 0a0f7ff

Browse files
committed
fix linting issues
1 parent 01204a5 commit 0a0f7ff

37 files changed

Lines changed: 161 additions & 158 deletions

compose.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,13 @@ export interface GamePort {
1313

1414
export const GAME_CONTAINER_NAME = "nodebyte-game";
1515

16-
export const escapeComposeValue = (value: string): string => value.replaceAll('"', '\\"');
16+
export const escapeComposeValue = (value: string): string =>
17+
value.replaceAll('"', '\\"');
1718

1819
const formatRange = (port: GamePort): string =>
1920
port.from === port.to ? `${port.from}` : `${port.from}:${port.to}`;
2021

2122
export const buildUfwRules = (ports: readonly GamePort[]): string[] =>
2223
ports.map(
23-
(port) => `ufw allow ${formatRange(port)}/${port.protocol} || true`,
24+
(port) => `ufw allow ${formatRange(port)}/${port.protocol} || true`
2425
);

cs2/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@ const buildCompose = (config: ComposeConfig, raw: unknown): string =>
99

1010
export const cs2 = {
1111
buildCompose,
12-
description: "The legendary tactical FPS. Plant the bomb, defuse it, or just frag your friends.",
12+
description:
13+
"The legendary tactical FPS. Plant the bomb, defuse it, or just frag your friends.",
1314
dockerImage,
1415
enabled: true,
1516
gamedigId: "cs2",

cs2/install.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ export const dockerImage = "joedwards32/cs2:latest";
66

77
export const buildCs2Compose = (
88
config: ComposeConfig,
9-
settings: Cs2Settings,
9+
settings: Cs2Settings
1010
): string => {
1111
const timezone = config.timezone ?? "UTC";
1212
const escape = escapeComposeValue;

cs2/settings.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,7 @@ export const cs2Settings = defineSettings({
6565
},
6666
steamToken: {
6767
default: "",
68-
help:
69-
"Steam Game Server Login Token (GSLT). Required for public servers — get one at steamcommunity.com/dev/managegameservers (App ID 730).",
68+
help: "Steam Game Server Login Token (GSLT). Required for public servers — get one at steamcommunity.com/dev/managegameservers (App ID 730).",
7069
label: "Steam GSLT",
7170
maxLength: 64,
7271
type: "string",

deno.json

Lines changed: 7 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -4,31 +4,15 @@
44
"indentWidth": 2,
55
"semiColons": true,
66
"singleQuote": false,
7-
"include": [
8-
"**/*.ts",
9-
"scripts/**/*.mjs"
10-
],
11-
"exclude": [
12-
".git/**",
13-
".github/**"
14-
]
7+
"include": ["**/*.ts", "scripts/**/*.mjs"],
8+
"exclude": [".git/**", ".github/**"]
159
},
1610
"lint": {
1711
"rules": {
18-
"exclude": [
19-
"no-process-global"
20-
],
21-
"tags": [
22-
"recommended"
23-
]
12+
"exclude": ["no-process-global"],
13+
"tags": ["recommended"]
2414
},
25-
"include": [
26-
"**/*.ts",
27-
"scripts/**/*.mjs"
28-
],
29-
"exclude": [
30-
".git/**",
31-
".github/**"
32-
]
15+
"include": ["**/*.ts", "scripts/**/*.mjs"],
16+
"exclude": [".git/**", ".github/**"]
3317
}
34-
}
18+
}

dontstarvetogether/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { dontStarveTogetherSettings } from "./settings";
77
const buildCompose = (config: ComposeConfig, raw: unknown): string =>
88
buildDontStarveTogetherCompose(
99
config,
10-
resolveSettings(dontStarveTogetherSettings, raw),
10+
resolveSettings(dontStarveTogetherSettings, raw)
1111
);
1212

1313
export const dontStarveTogether = {

dontstarvetogether/install.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ export const dockerImage = "webhippie/dst:latest";
66

77
export const buildDontStarveTogetherCompose = (
88
config: ComposeConfig,
9-
settings: DontStarveTogetherSettings,
9+
settings: DontStarveTogetherSettings
1010
): string => {
1111
const timezone = config.timezone ?? "UTC";
1212
const escape = escapeComposeValue;

enshrouded/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@ const buildCompose = (config: ComposeConfig, raw: unknown): string =>
99

1010
export const enshrouded = {
1111
buildCompose,
12-
description: "A game of survival, crafting, and action on a sprawling voxel-based continent.",
12+
description:
13+
"A game of survival, crafting, and action on a sprawling voxel-based continent.",
1314
dockerImage,
1415
enabled: true,
1516
gamedigId: "enshrouded",

enshrouded/install.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ export const dockerImage = "mornedhels/enshrouded-server:latest";
66

77
export const buildEnshroudedCompose = (
88
config: ComposeConfig,
9-
settings: EnshroudedSettings,
9+
settings: EnshroudedSettings
1010
): string => {
1111
const timezone = config.timezone ?? "UTC";
1212
const escape = escapeComposeValue;

fivem/install.ts

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ const yamlBlock = (lines: string[], indent = 10) =>
1414

1515
export const buildFivemCompose = (
1616
config: ComposeConfig,
17-
settings: FivemSettings,
17+
settings: FivemSettings
1818
): string => {
1919
const timezone = config.timezone ?? "UTC";
2020
const escape = escapeComposeValue;
@@ -75,7 +75,9 @@ export const buildFivemCompose = (
7575
// When txAdmin is disabled, +exec server.cfg is passed so the server reads
7676
// configuration on startup. When txAdmin is enabled, txAdmin handles that
7777
// itself — omitting +exec server.cfg lets txAdmin take over.
78-
const noTxAdminSuffix = settings.enableTxAdmin ? "" : " \\\n +exec server.cfg";
78+
const noTxAdminSuffix = settings.enableTxAdmin
79+
? ""
80+
: " \\\n +exec server.cfg";
7981
const startupLines = [
8082
`exec ${DATA}/alpine/opt/cfx-server/ld-musl-x86_64.so.1 \\`,
8183
` --library-path "${DATA}/alpine/usr/lib/v8/:${DATA}/alpine/lib/:${DATA}/alpine/usr/lib/" \\`,
@@ -90,14 +92,16 @@ export const buildFivemCompose = (
9092
// txAdmin requires its own port and additional env vars.
9193
const txAdminEnvLines = settings.enableTxAdmin
9294
? [
93-
` TXADMIN_ENABLE: "1"`,
94-
` TXHOST_GAME_NAME: "fivem"`,
95-
` TXHOST_TXA_PORT: "40120"`,
96-
` TXHOST_DATA_PATH: "${DATA}/txData"`,
97-
].join("\n")
95+
` TXADMIN_ENABLE: "1"`,
96+
` TXHOST_GAME_NAME: "fivem"`,
97+
` TXHOST_TXA_PORT: "40120"`,
98+
` TXHOST_DATA_PATH: "${DATA}/txData"`,
99+
].join("\n")
98100
: ` TXADMIN_ENABLE: "0"`;
99101

100-
const txAdminPort = settings.enableTxAdmin ? `\n - "40120:40120/tcp"` : "";
102+
const txAdminPort = settings.enableTxAdmin
103+
? `\n - "40120:40120/tcp"`
104+
: "";
101105

102106
return `services:
103107
# Bootstrap: downloads FXServer + cfx-server-data on first deploy.

0 commit comments

Comments
 (0)