- Convert role management from prefix to slash commands (/role add/remove/list) - Update database schema to store role IDs as JSON arrays instead of regex patterns - Add /config roles command for administrators to manage allowed roles - Simplify database schema by reusing allowed_roles_for_request field as JSON - Add database reset script (pnpm reset-db) for easy testing and migration - Update config format to only support array format (no backward compatibility) Role Management Features: - /role add <role> - Self-assign roles with dropdown selection - /role remove <role> - Remove roles with dropdown selection - /role list - Show available self-assignable roles - /config roles add/remove/list/clear - Administrator role management Technical Improvements: - Role ID based matching (more reliable than name-based regex) - Type-safe role selection with Discord's native role picker - Permission hierarchy validation - Rich embed responses with proper error handling - Ephemeral responses for clean chat experience 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
42 lines
1.3 KiB
JSON
42 lines
1.3 KiB
JSON
{
|
|
"name": "ghbot",
|
|
"version": "2.0.0",
|
|
"description": "",
|
|
"main": "src/index.js",
|
|
"dependencies": {
|
|
"@discordjs/opus": "^0.9.0",
|
|
"@discordjs/voice": "^0.18.0",
|
|
"axios": "^1.11.0",
|
|
"better-sqlite3": "^11.10.0",
|
|
"discord.js": "^14.21.0",
|
|
"ffmpeg-static": "^5.2.0",
|
|
"node-schedule": "^2.1.1",
|
|
"opusscript": "^0.1.1",
|
|
"sodium-native": "^4.3.3"
|
|
},
|
|
"devDependencies": {
|
|
"@types/node": "^22.17.2",
|
|
"nodemon": "^3.1.10"
|
|
},
|
|
"pnpm": {
|
|
"overrides": {
|
|
"@discordjs/opus": "npm:opusscript@^0.1.1"
|
|
}
|
|
},
|
|
"scripts": {
|
|
"dev": "nodemon src/index.js",
|
|
"start": "docker compose up -d",
|
|
"start:logs": "pnpm start && pnpm logs",
|
|
"stop": "docker compose down",
|
|
"build": "docker compose build",
|
|
"restart": "docker compose restart",
|
|
"logs": "docker compose logs -f",
|
|
"boom": "pnpm stop && pnpm build && pnpm start",
|
|
"reset-db": "pnpm stop && rm -f data/ghbot.db data/ghbot.db-shm data/ghbot.db-wal && echo 'Database reset complete. Run pnpm start to re-seed from config.json'",
|
|
"image:build": "docker build -t ghbot:${VERSION:-latest} .",
|
|
"image:run": "docker run -d --name ghbot --restart always ghbot:${VERSION:-latest}"
|
|
},
|
|
"author": "https://github.com/greenham",
|
|
"license": "MIT"
|
|
}
|