Clean up env vars, provide example file
This commit is contained in:
parent
4390bc5c64
commit
2af6e35842
6
example.env
Normal file
6
example.env
Normal file
@ -0,0 +1,6 @@
|
||||
TOKEN=
|
||||
OWNER_ID=
|
||||
STATUS_CHANNEL_ID=
|
||||
DEBUG=
|
||||
HEARTBEAT_URL=
|
||||
BOT_ID=
|
4
main.js
4
main.js
@ -16,8 +16,8 @@ const client = new Client({
|
||||
// Various imports
|
||||
const fn = require('./modules/functions.js');
|
||||
const strings = require('./data/strings.json');
|
||||
const isDev = process.env.DEBUG;
|
||||
const statusChannelId = process.env.STATUSCHANNELID;
|
||||
const isDev = process.env.DEBUG === "true";
|
||||
const statusChannelId = process.env.STATUS_CHANNEL_ID;
|
||||
|
||||
client.once('ready', () => {
|
||||
// Build a collection of slash commands for the bot to use
|
||||
|
@ -4,7 +4,7 @@ dotenv.config();
|
||||
|
||||
const { REST } = require('@discordjs/rest');
|
||||
const { Routes } = require('discord-api-types/v9');
|
||||
const clientId = process.env.BOTID;
|
||||
const clientId = process.env.BOT_ID;
|
||||
const token = process.env.TOKEN;
|
||||
const fs = require('fs');
|
||||
|
||||
|
@ -4,7 +4,7 @@ dotenv.config();
|
||||
|
||||
const { REST, Routes } = require('discord.js');
|
||||
const { guildId } = require('../data/config.json');
|
||||
const clientId = process.env.clientId;
|
||||
const clientId = process.env.BOT_ID;
|
||||
const token = process.env.TOKEN;
|
||||
const fs = require('fs');
|
||||
|
||||
|
@ -4,7 +4,7 @@ dotenv.config();
|
||||
|
||||
const { REST } = require('@discordjs/rest');
|
||||
const { Routes } = require('discord-api-types/v9');
|
||||
const clientId = process.env.clientId;
|
||||
const clientId = process.env.BOT_ID;
|
||||
const { guildId } = require('../data/config.json');
|
||||
const token = process.env.TOKEN;
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
// dotenv for handling environment variables
|
||||
const dotenv = require('dotenv');
|
||||
dotenv.config();
|
||||
const isDev = process.env.isDev;
|
||||
const isDev = process.env.DEBUG === "true";
|
||||
|
||||
// filesystem
|
||||
const fs = require('fs');
|
||||
|
Loading…
Reference in New Issue
Block a user