import { commands } from '../src/discord/commands'; import { registerCommands } from '../src/discord/registration'; if (process.argv.includes('--apply')) { const registered = await registerCommands(process.env.DISCORD_CLIENT_ID ?? '', process.env.DISCORD_BOT_TOKEN ?? '', commands); console.log(`Registered global commands for servers and bot DMs: ${registered.map(name => `/${name}`).join(', ')}`); } else { console.log(JSON.stringify(commands, null, 2)); console.log('Preview only. Add --apply to register these commands with Discord.'); }