Guidelines
Code style
Section titled “Code style”Rust code follows standard rustfmt formatting and must pass clippy with
-D warnings (all warnings are errors). No additional style configuration is
needed — the defaults apply.
Zig code follows Zig standard style. Run zig fmt on changed files.
Commit messages use conventional commits:
| Prefix | Use for |
|---|---|
feat: | New functionality |
fix: | Bug fixes |
docs: | Documentation changes |
refactor: | Code restructuring without behavior change |
test: | Adding or updating tests |
perf: | Performance improvements |
chore: | Build, CI, or tooling changes |
Testing requirements
Section titled “Testing requirements”Every code change needs tests. The rule is simple: if you change behavior, a test must cover it.
- New features — write tests that exercise the new code paths
- Bug fixes — add a regression test that fails on the old behavior
- Refactoring — existing tests must continue to pass; add tests if coverage gaps exist
Run the full test suite before submitting:
cargo nextest runFor Zig changes:
cd zig && zig build testPull request process
Section titled “Pull request process”- Create a feature branch from
main - Make your changes with tests
- Ensure all pre-commit hooks pass (
lefthook run pre-commit) - Push your branch and open a pull request
- PR title should follow conventional commit format
- Wait for CI and code review
Keep PRs focused — one logical change per PR. Large changes should be split into a series of smaller PRs when possible.
Version bumping
Section titled “Version bumping”Version changes are handled through a guided release workflow. When a version bump is needed, three locations must be updated together:
Cargo.toml— workspace version fieldmarkymark-plugin/.claude-plugin/plugin.json— plugin version (not auto-derived)Cargo.lock— regenerated by runningcargo buildafter the version change
See the release documentation for the full process.
License
Section titled “License”markymark is licensed under AGPL-3.0-only. All contributions are made under this license. By submitting a pull request, you agree that your contribution is licensed under the same terms.