From 287d57c841f3789aca9570b2e2a37d933e104efd Mon Sep 17 00:00:00 2001 From: Sainan <63328889+Sainan@users.noreply.github.com> Date: Wed, 30 Jul 2025 01:23:44 +0200 Subject: [PATCH] chore: rename config.json.example to config-vanilla.json Renaming file extensions can be a bit of a chore on stock Windows, so this should simplify matters. Another bonus is that the "vanilla" clarifies the general guideline for how the defaults are configured. --- .github/workflows/build.yml | 2 +- .prettierignore | 2 +- README.md | 2 +- config.json.example => config-vanilla.json | 0 docker-entrypoint.sh | 2 +- src/index.ts | 2 +- 6 files changed, 5 insertions(+), 5 deletions(-) rename config.json.example => config-vanilla.json (100%) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 375beec1..29b60ea1 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -14,7 +14,7 @@ jobs: with: node-version: ">=20.6.0" - run: npm ci - - run: cp config.json.example config.json + - run: cp config-vanilla.json config.json - run: npm run verify - run: npm run lint:ci - run: npm run prettier diff --git a/.prettierignore b/.prettierignore index 9ce8be88..e1ab4819 100644 --- a/.prettierignore +++ b/.prettierignore @@ -2,4 +2,4 @@ src/routes/api.ts static/webui/libs/ *.html *.md -config.json.example +config-vanilla.json diff --git a/README.md b/README.md index 0985b846..cd136b9f 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ To get an idea of what functionality you can expect to be missing [have a look t ## config.json -SpaceNinjaServer requires a `config.json`. To set it up, you can copy the [config.json.example](config.json.example), which has most cheats disabled. +SpaceNinjaServer requires a `config.json`. To set it up, you can copy the [config-vanilla.json](config-vanilla.json), which has most cheats disabled. - `logger.level` can be `fatal`, `error`, `warn`, `info`, `http`, `debug`, or `trace`. - `myIrcAddresses` can be used to point to an IRC server. If not provided, defaults to `[ myAddress ]`. diff --git a/config.json.example b/config-vanilla.json similarity index 100% rename from config.json.example rename to config-vanilla.json diff --git a/docker-entrypoint.sh b/docker-entrypoint.sh index 703b7eaf..27abf98d 100755 --- a/docker-entrypoint.sh +++ b/docker-entrypoint.sh @@ -2,7 +2,7 @@ set -e if [ ! -f conf/config.json ]; then - jq --arg value "mongodb://openwfagent:spaceninjaserver@mongodb:27017/" '.mongodbUrl = $value' /app/config.json.example > /app/conf/config.json + jq --arg value "mongodb://openwfagent:spaceninjaserver@mongodb:27017/" '.mongodbUrl = $value' /app/config-vanilla.json > /app/conf/config.json fi exec npm run start -- --configPath conf/config.json diff --git a/src/index.ts b/src/index.ts index 4887db86..175ce189 100644 --- a/src/index.ts +++ b/src/index.ts @@ -7,7 +7,7 @@ try { if (fs.existsSync("config.json")) { console.log("Failed to load " + configPath + ": " + (e as Error).message); } else { - console.log("Failed to load " + configPath + ". You can copy config.json.example to create your config file."); + console.log("Failed to load " + configPath + ". You can copy config-vanilla.json to create your config file."); } process.exit(1); }