[NPM] Remove dotenv as a dependency. (#17)

This commit is contained in:
2026-09-28 06:49:04 -07:00
committed by GitHub
parent 4eb3d2bb34
commit 22da1c5a80
5 changed files with 4 additions and 27 deletions
-12
View File
@@ -9,7 +9,6 @@
"@redis/client": "5.1.0",
"body-parser": "2.3.0",
"discord.js": "14.27.0",
"dotenv": "16.5.0",
"express": "5.1.0",
"express-session": "1.19.0",
"markdown-it": "15.0.0",
@@ -1894,17 +1893,6 @@
"url": "https://github.com/discordjs/discord.js?sponsor"
}
},
"node_modules/dotenv": {
"version": "16.5.0",
"resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.5.0.tgz",
"integrity": "sha512-m/C+AwOAr9/W1UOIZUo232ejMNnJAJtYQjUbHoNTBNTJSvqzzDh7vnrei3o3r3m9blf6ZoDkvcw0VmozNRFJxg==",
"engines": {
"node": ">=12"
},
"funding": {
"url": "https://dotenvx.com"
}
},
"node_modules/dunder-proto": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz",
+4 -5
View File
@@ -18,7 +18,6 @@
"@redis/client": "5.1.0",
"body-parser": "2.3.0",
"discord.js": "14.27.0",
"dotenv": "16.5.0",
"express": "5.1.0",
"express-session": "1.19.0",
"markdown-it": "15.0.0",
@@ -27,14 +26,14 @@
"sqlite3": "6.0.1"
},
"scripts": {
"dev": "tsx watch --enable-source-maps src/index.ts",
"start": "node dist/index.js",
"dev": "tsx watch --enable-source-maps --env-file=.env src/index.ts",
"start": "node --env-file=.env dist/index.js",
"lint": "npx eslint .",
"typecheck": "npx tsc --noEmit",
"build": "npm run clean && node scripts/build.js && npm run copyfiles",
"clean": "rimraf dist",
"copyfiles": "copyfiles -u 1 \"./src/**/*.html\" ./dist",
"encrypt": "node ./scripts/encrypt-data.js",
"add-author-hash": "node ./scripts/add-author-id-hash.js"
"encrypt": "node --env-file=.env ./scripts/encrypt-data.js",
"add-author-hash": "node --env-file=.env ./scripts/add-author-id-hash.js"
}
}
-3
View File
@@ -1,10 +1,7 @@
import crypto from 'crypto';
import dotenv from 'dotenv';
import { open } from 'sqlite';
import sqlite3 from 'sqlite3';
dotenv.config();
async function main() {
Encrypter.initialize(process.env.DATABASE_SECRET);
-3
View File
@@ -1,10 +1,7 @@
import crypto from 'crypto';
import dotenv from 'dotenv';
import { open } from 'sqlite';
import sqlite3 from 'sqlite3';
dotenv.config();
async function main() {
Encrypter.initialize(process.env.DATABASE_SECRET);
-4
View File
@@ -1,7 +1,3 @@
import dotenv from 'dotenv';
dotenv.config();
const { DISCORD_TOKEN, DISCORD_CLIENT_ID, DISCORD_CLIENT_SECRET, DISCORD_GUILD_ID, RELEASE_SECRET, DATABASE_SECRET, LINK_SECRET, E621_BASE_URL, E926_BASE_URL, PRIVACY_POLICY_URL, GIT_REPO_BASE_URL, REDIS_URL, PORT, DEBUG } = process.env;
export const config = {