Contributing
Contributions are welcome from everyone — Graven - Développement community staff and members alike. This project is developed for and by the Graven - Développement Discord community.
Getting Started
- Fork the repository on GitHub
- Clone your fork
- Set up the development environment (see Getting Started)
- Create a branch for your work
bash
git checkout -b feat/my-featureConventional Commits
Commit messages must follow the Conventional Commits format. This is enforced by commitlint via a lefthook commit-msg hook.
type(scope): description
feat(thread-creator): add paced creation queue
fix(config): handle undefined values in number handler
docs(commands): explain autocomplete flow
chore(deps): update pnpm to v11Allowed Types
| Type | Usage |
|---|---|
feat | A new feature |
fix | A bug fix |
chore | Maintenance, dependencies, tooling |
docs | Documentation changes |
refactor | Code restructuring without feature changes |
test | Adding or updating tests |
ci | CI/CD configuration changes |
Before Opening a PR
Run these checks locally — the same checks run in CI:
bash
pnpm build # Must succeed
pnpm test # All tests must pass (unit + integration)
pnpm exec oxlint --deny-warnings # No lint warnings
pnpm exec oxfmt --check # Code formatting must be correctTo auto-fix formatting and lint issues:
bash
pnpm format # oxfmt --write + oxlint --fix --fix-suggestionsPR Workflow
- Branch from
master— keep your branch up to date - Make focused commits — each commit should represent one logical change
- Keep PRs small — easier to review, faster to merge
- Open a draft PR early — get feedback while you work
- Ensure CI is green — fix any failing checks
- Request review — at least one approval required
PR Title Convention
Follow the same Conventional Commits format for PR titles:
feat(module): add message logging functionality
fix(core): resolve permission check race conditionCode Style
Formatting
- oxfmt handles all formatting (replaces Prettier)
- Run
pnpm formatbefore committing - The
pre-commitlefthook hook runs oxfmt + oxlint on staged files
Linting
- oxlint enforces code quality rules
- Run
pnpm exec oxlint --deny-warningsto check - Some warnings can be auto-fixed with
pnpm format
Imports
- Cross-directory: use
#subpath imports (#lib/config.js,#core/...) - Same-directory: use relative imports (
./file.js) - Always include the
.jsextension (NodeNext)
Naming
- Files use role suffixes:
*.command.ts,*.listener.ts,*.button.ts,*.service.ts - Module IDs are kebab-case:
thread-creator,my-module - Types and interfaces are PascalCase
Testing
We use Vitest for testing. Tests are co-located with source files:
src/lib/config.ts # Source
src/lib/config.test.ts # Tests
src/core/services/module.service.ts
src/core/services/module.service.test.tsRunning Tests
bash
pnpm test # All tests
pnpm test:unit # Unit tests only
pnpm test:integration # Integration tests only
pnpm test -- --watch # Watch modeWriting Tests
- Unit tests test isolated logic (parsers, utilities, algorithms)
- Integration tests test interactions with Discord API (mocked) and database
- Tests use
vi.mock()to isolate dependencies - Check existing tests for patterns and conventions
Finding Tasks
- AUDIT.md — tracks tech debt, known issues, and follow-ups
- GitHub Issues — feature requests and bug reports
- Review docs — code review findings with actionable items
Need Help?
- Join the Graven - Développement Discord server
- Open a GitHub Discussion
- Check the documentation for guides and reference