Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion config/development.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ const config: Config = {
adminTokens: secret.development.auth.adminTokens
},
features: ["scouting", "resources", "tps"],
year: 2025
year: 2026
};

export default config;
30 changes: 30 additions & 0 deletions config/examplesecret.json
Original file line number Diff line number Diff line change
Expand Up @@ -130,5 +130,35 @@
"admin": "admin"
}
}
},
"production2025": {
"db": {
"database": "tpw-prod",
"username": "",
"password": "",
"host": "localhost",
"port": 27017
},
"auth": {
"cookieKeys": ["1", "2", "3", "4", "I declare a thumb war"],
"access": {
"restricted": false,
"username": "admin",
"password": "admin"
},
"ci": {
"deploy": ""
},
"scoutingKeys": ["1", "2", "3", "4", "I declare a thumb war"],
"tba": "",
"scoutingAdmins": ["admin"],
"scoutingInternal": {
"teamNumber": "admin",
"accessToken": "admin"
},
"adminTokens": {
"admin": "admin"
}
}
}
}
5 changes: 4 additions & 1 deletion config/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import staging from "./staging";
import production from "./production";
import production2023 from "./production2023";
import production2024 from "./production2024";
import production2025 from "./production2025";

const env = process.env.NODE_ENV || "development";

Expand All @@ -12,14 +13,16 @@ if (
"staging",
"production",
"production2023",
"production2024"
"production2024",
"production2025"
].includes(env)
)
throw new Error(`Config file for environment ${env} could not be found.`);
const config: Config = {
production,
production2023,
production2024,
production2025,
staging,
development
}[env];
Expand Down
2 changes: 1 addition & 1 deletion config/production.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const config: Config = {
db: secret.production.db,
auth: secret.production.auth,
features: ["scouting", "tps"],
year: 2025
year: 2026
};

export default config;
17 changes: 17 additions & 0 deletions config/production2025.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import { Config } from ".";
// @ts-ignore
import secret from "./secret";

const config: Config = {
branch: "2025",
server: {
port: 18925,
domain: "2025.thepurplewarehouse.com"
},
db: secret.production2025.db,
auth: secret.production2025.auth,
features: ["scouting", "tps"],
year: 2025
};

export default config;
5 changes: 5 additions & 0 deletions config/scouting/2026/exampleaccuracy.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
let accuracy = async function (event, matches, data, categories, teams) {
return {};
};

export default accuracy;
Loading