From 656b0b0e88f8970022e63ddeb61e45776c4a2233 Mon Sep 17 00:00:00 2001 From: Daniel Odendahl Jr Date: Sat, 28 Apr 2018 20:28:11 +0000 Subject: [PATCH] public stuff --- README.md | 9 ++++++++- commands/role-manage/subscribe.js | 1 - commands/role-manage/unsubscribe.js | 1 - commands/util/invite.js | 26 ++++++++++++++++++++++++++ package.json | 2 +- 5 files changed, 35 insertions(+), 4 deletions(-) create mode 100644 commands/util/invite.js diff --git a/README.md b/README.md index d91d598d..ccb05e87 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,13 @@ Xiao is a Discord bot coded in JavaScript with [Commando](https://github.com/discordjs/Commando) command framework. With over 300 commands, she is one of the most feature-filled bots out there. -## Commands (307) +## Invite +You can invite the bot to your server using +[this link](https://discordapp.com/oauth2/authorize?client_id=278305350804045834&scope=bot&permissions=372632641). +Be sure to also join the [home server](https://discord.gg/sbMe32W) for +information and support. + +## Commands (308) ### Utility: * **prefix**: Shows or sets the command prefix. @@ -18,6 +24,7 @@ Xiao is a Discord bot coded in JavaScript with * **donate**: Responds with Xiao's donation links. * **help**: Displays a list of available commands, or detailed information for a specific command. * **info**: Responds with detailed bot information. +* **invite**: Responds with Xiao's invite links. * **ping**: Checks the bot's ping to the Discord server. * **uptime**: Responds with how long the bot has been active. * **whitelist**: Removes a user from the blacklist. diff --git a/commands/role-manage/subscribe.js b/commands/role-manage/subscribe.js index 37393aea..90c518d0 100644 --- a/commands/role-manage/subscribe.js +++ b/commands/role-manage/subscribe.js @@ -4,7 +4,6 @@ module.exports = class SubscribeCommand extends Command { constructor(client) { super(client, { name: 'subscribe', - aliases: ['join'], group: 'role-manage', memberName: 'subscribe', description: 'Subscribes you to the specified role.', diff --git a/commands/role-manage/unsubscribe.js b/commands/role-manage/unsubscribe.js index 6d77398a..7677dbdb 100644 --- a/commands/role-manage/unsubscribe.js +++ b/commands/role-manage/unsubscribe.js @@ -4,7 +4,6 @@ module.exports = class UnsubscribeCommand extends Command { constructor(client) { super(client, { name: 'unsubscribe', - aliases: ['leave'], group: 'role-manage', memberName: 'unsubscribe', description: 'Unsubscribes you from the specified role.', diff --git a/commands/util/invite.js b/commands/util/invite.js new file mode 100644 index 00000000..c4c2d0e4 --- /dev/null +++ b/commands/util/invite.js @@ -0,0 +1,26 @@ +const { Command } = require('discord.js-commando'); +const { stripIndents } = require('common-tags'); + +module.exports = class InviteCommand extends Command { + constructor(client) { + super(client, { + name: 'invite', + aliases: ['join'], + group: 'util', + memberName: 'invite', + description: 'Responds with Xiao\'s invite links.', + guarded: true + }); + } + + async run(msg) { + const invite = await this.client.generateInvite('372632641'); + return msg.say(stripIndents` + To invite me to your server, use this link: + <${invite}> + + Or, join my home server: + ${this.client.options.invite || 'Coming soon...'} + `); + } +}; diff --git a/package.json b/package.json index 01fbe238..a1c9d1be 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "xiao", - "version": "74.0.0", + "version": "75.0.0", "description": "Your personal server companion.", "main": "Xiao.js", "scripts": {