Contributing
Tealhand is open source, and pull requests are welcome. These rules keep the safety promises true.
How a change goes in
Section titled “How a change goes in”- Open an issue first for anything bigger than a small fix, and always for a change to one of the five safety rules.
- Work on a branch of your fork.
mainis the shared branch; a maintainer reviews and merges. - Keep pull requests small, one topic each, and say in the description what you tested.
- Add tests for what you change. A bug fix comes with a test that failed before the fix.
- Sign off every commit (Developer Certificate of Origin):
git commit -s, which adds aSigned-off-by:line with your name and email. - Run the checks before you push: run
scripts/ci-local.sh. CI runs only onmainand on pull requests, so a push to a feature branch is not checked for you. Build from source lists the checks one by one; CI runs the same ones on Ubuntu and Windows.
For the steps a feature goes through, the rules in full and how to add an action, read How a feature is made.
Rules that do not bend
Section titled “Rules that do not bend”- No
unsafein our code. The workspace setsunsafe_code = "forbid"for every crate. The only exceptions are isolated crates with a tiny API and no parsing or networking inside (tealhand-ffi, and latertealhand-wincam). Adding one needs an issue and the maintainers’ written approval first. The full policy:docs/unsafe.md. - No code copied from other projects, whatever its licence. Take ideas, not code. The only outside code is
well-maintained dependencies that pass
cargo denyandcargo audit. Say in the pull request if a new dependency, or its tree, addsunsafe. - Permissive licences only for dependencies. A copyleft dependency needs the maintainers’ OK and its own
exception in
deny.toml. - Never commit secrets: keys, tokens, certificates, real server addresses or personal data. Use
placeholders such as
relay.example.comand203.0.113.10, and.env.examplefor settings. - No content in logs: never sentences, file contents, keys or process names.
- Wire formats are append-only. Never reorder or remove a variant of a wire enum; add new ones at the end. A protocol change bumps the capability version.
- Actions come only from the action list. A new action goes into
tealhand-actionswith its risk level, its card text, its origin flags and tests.
Licences of contributions
Section titled “Licences of contributions”Contributions to the apps, the core and Tealhand Host are under Apache-2.0. Contributions to Tealhand Relay are under AGPL-3.0-only. Releases are built and signed by the Teal team only.
Security problems
Section titled “Security problems”Do not open a public issue. See Reporting a vulnerability.
The docs
Section titled “The docs”This site is in docs-site/. Every command, option, default and limit in it must match the code; if you change
one in the code, change the page in the same pull request.