2023-08-27 12:44:58 +00:00
|
|
|
const { SlashCommandBuilder, EmbedBuilder, Client } = require("discord.js");
|
|
|
|
const { __glob } = require("../modules/global-variables");
|
|
|
|
const pm2 = require("pm2")
|
|
|
|
|
|
|
|
module.exports = {
|
|
|
|
|
|
|
|
data: new SlashCommandBuilder()
|
|
|
|
.setName("restart")
|
2023-09-15 20:10:11 +00:00
|
|
|
.setDescription("Redémarre intégralement le Bot !"),
|
2023-08-27 12:44:58 +00:00
|
|
|
|
|
|
|
async execute(client, interaction) {
|
|
|
|
|
|
|
|
const membed = new EmbedBuilder()
|
|
|
|
.setColor(0xffffff)
|
|
|
|
.setTitle('Redémarrage du bot !')
|
|
|
|
|
2023-08-27 12:47:20 +00:00
|
|
|
await interaction.reply({embeds: [membed]})
|
2023-08-27 12:44:58 +00:00
|
|
|
|
2024-02-05 21:49:15 +00:00
|
|
|
pm2.restart("Subsonics")
|
2023-08-27 12:44:58 +00:00
|
|
|
|
|
|
|
}
|
|
|
|
|
2024-02-05 21:49:15 +00:00
|
|
|
}
|
|
|
|
|