Skip to content

Commit

Permalink
Update deploy command script to api v10
Browse files Browse the repository at this point in the history
  • Loading branch information
connorhsm committed Jul 24, 2022
1 parent 548831a commit e5ddb61
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
13 changes: 11 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,18 @@ Run latest dev image

Deploy commands
`export DEV/PROD_TOKEN=thetoken`
`export GUILDID=id`
`export CLIENTID=id`
`export GUILDID=id` (Defaults to dev token if unset)
`export CLIENTID=id` (Defaults to dev token if unset)
`node deploy-commands.js`

Webhook
`webhook -hooks /var/webhook/hooks.json -verbose -port 9000 -hotreload`

Use correct node version
`nvm use (version)` *Always check the Dockerfile for the current version of Node this project is developed against.*

Update packages
`npm update`

Better way to update packages (Will tell you about any new versions, including major)
`npx npm-check-updates` provide `-u` for the program to update them itself
2 changes: 1 addition & 1 deletion deploy-commands.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ for (const file of commandFiles) {
commands.push(command.data.toJSON());
};

const rest = new REST({ version: '9' }).setToken(process.env.DEV_TOKEN ? process.env.DEV_TOKEN : process.env.PROD_TOKEN);
const rest = new REST({ version: '10' }).setToken(process.env.DEV_TOKEN ? process.env.DEV_TOKEN : process.env.PROD_TOKEN);

(async () => {
try {
Expand Down

0 comments on commit e5ddb61

Please sign in to comment.