Thanks for your interest. cofi is a small C/GTK3 window switcher; this guide covers the contributor surface. Agent-facing rules live in CLAUDE.md and product behavior in SPEC.md.
make clean && make # build
make test # 70 test binaries
./restart.sh # rebuild + restart systemd user service
bash scripts/install-hooks.sh # one-time: install pre-push hookSee README.md for runtime usage and docs/glossary.md for domain terms.
main— stable, updated via PR fromdevelopdevelop— default target for all PRsfeat/*,fix/*,chore/*,docs/*— short-lived topic branches offdevelop
Branch from develop, never from main. Never push directly to develop, main, or release.
- Add or update tests for behavior changes. The runner is
make test; entries live inMakefileandtest/*.c. - For refactors, write behavioral tests against current code first; they must still pass after.
- If a UI/X11 path is hard to cover, say so in the PR — don't skip silently.
Imperative mood. Conventional-style type prefix when useful:
feat: add jump-slot command for per-workspace slot activation
fix: recompute window size + recenter on each show
docs: add glossary
Body explains why, not what — well-named code already shows the what.
- Run
make testlocally (the pre-push hook will run it again in a temporary worktree for the ref tip being pushed). - Push the branch — GitHub Actions runs the
Buildworkflow (compile +make test) on every push. - Open a PR targeting
develop. Include a short summary and a test plan. - Wait for the maintainer to review and merge. Don't self-merge.
Use the GitHub issue tracker for bugs and feature requests. Reference Linear ticket IDs (TFD-NN) in PRs when relevant; the maintainer manages the Linear board.
See CLAUDE.md → Design Principles and Coding Guidelines. Highlights:
snake_casefor functions and variables- Small functions (10–15 lines, max 30)
- One module = one responsibility
- Logging via
log_*helpers, neverprintf make clean && makeafter header changes (no auto header deps yet)