Before continuing you must install Node.js to your PC. Link here: https://nodejs.org/en/download/
- Add this code to the "process.json" file:
- Open Command Prompt or Powershell and change directory to the root directory
- Type the following into your Command Prompt or Powershell:
npm install
- After creating your "process.json" file with Command Prompt or Powershell still open type:
npm start
{
"env":
{
"prefix": "[Your-Prefix-Here]",
"token": "[Your-Discord-Bot-Token-Here]"
}
}
The bot is now online
###################################
###################################
- Ensure line 6 of index.js (located in the file named "src") is commented
- Add code to Heroku
- Go to settings tab on Heroku and set config vars "prefix" and "token" with your prefix and Discord bot token respectively
- Deploy on Heroku
The bot is now online
Note: Ensure that the ONLY active dyno is "worker" in the resources tab on Heroku