mirror of
https://github.com/zhom/donutbrowser.git
synced 2026-08-05 02:38:44 +02:00
chore: ai compliance
This commit is contained in:
+30
-20
@@ -1,6 +1,16 @@
|
||||
# Contributing to Donut Browser
|
||||
|
||||
Contributions are welcome! Please do not create PRs for the sake of being added to the contributors list. Reviewing PRs takes time, so please create PRs only if you believe that your change will improve Donut for yourself and others. If you are thinking of making a significant change, please get in touch with the maintainer first.
|
||||
Contributions are welcome. Don't open a PR just to get added to the contributors list. Reviewing PRs takes time, so open one only if you believe the change improves Donut for yourself and others. For a significant change, get in touch with the maintainer first.
|
||||
|
||||
## AI Policy
|
||||
|
||||
AI can write your code. It cannot speak for you, and it cannot be a co-author.
|
||||
|
||||
- Disclose it, always. Every PR must say whether AI was used. The template has two boxes and exactly one must be ticked. Neither ticked, both ticked, or the section deleted, and a bot closes the PR. Issues carry the same question.
|
||||
- No AI co-authors. A commit carrying a `Co-Authored-By:` trailer naming an AI tool, or a "Generated with ..." attribution, closes the PR. Strip them before pushing; `git commit --amend` or a rebase is enough. Most coding agents add these by default, so check.
|
||||
- Write your own words. Commit messages, PR descriptions, and replies in review must be yours. Broken English is welcome here; people contribute from everywhere and I would much rather read theirs. AI English is not welcome: it is long, evenly confident, and costs a reviewer time in proportion to how good it sounds.
|
||||
|
||||
Disclosing AI use is never held against you. Hiding it is what gets a PR closed.
|
||||
|
||||
## Before Starting
|
||||
|
||||
@@ -10,7 +20,7 @@ Contributions are welcome! Please do not create PRs for the sake of being added
|
||||
|
||||
## Contributor License Agreement
|
||||
|
||||
By contributing, you agree your contributions will be licensed under the same terms as the project. See [Contributor License Agreement](CONTRIBUTOR_LICENSE_AGREEMENT.md). This ensures contributions can be used in the open source version (AGPL-3.0) and commercially licensed. You retain all rights to use your contributions elsewhere.
|
||||
By contributing, you agree your contributions will be licensed under the same terms as the project. See [Contributor License Agreement](CONTRIBUTOR_LICENSE_AGREEMENT.md). This lets contributions be used in the open source version (AGPL-3.0) and commercially licensed. You retain all rights to use your contributions elsewhere.
|
||||
|
||||
## Development Setup
|
||||
|
||||
@@ -49,12 +59,12 @@ pnpm format && pnpm lint && pnpm test
|
||||
|
||||
This runs:
|
||||
|
||||
- **Biome**: JS/TS linting and formatting
|
||||
- **Clippy + rustfmt**: Rust linting and formatting
|
||||
- **typos**: Spellcheck (allowlist in `_typos.toml`)
|
||||
- **CodeQL**: Security analysis (JS, Actions, Rust), runs in CI
|
||||
- **Unit tests**: 330+ Rust tests
|
||||
- **Integration tests**: proxy, sync e2e
|
||||
- Biome: JS/TS linting and formatting
|
||||
- Clippy + rustfmt: Rust linting and formatting
|
||||
- typos: Spellcheck (allowlist in `_typos.toml`)
|
||||
- CodeQL: Security analysis (JS, Actions, Rust), runs in CI
|
||||
- Unit tests: 330+ Rust tests
|
||||
- Integration tests: proxy, sync e2e
|
||||
|
||||
### Running CodeQL locally
|
||||
|
||||
@@ -73,11 +83,11 @@ codeql database analyze /tmp/codeql-rust --format=sarifv2.1.0 --output=/tmp/rust
|
||||
|
||||
## Key Rules
|
||||
|
||||
- **Translations**: Any UI text changes must be reflected in all 9 locale files (`src/i18n/locales/`)
|
||||
- **Tauri commands**: If you modify Tauri commands, the `test_no_unused_tauri_commands` test will catch unused ones
|
||||
- **No hardcoded colors**: Use theme CSS variables (see `src/lib/themes.ts`), never Tailwind color classes like `text-red-500`
|
||||
- **No lock file changes**: Don't update `pnpm-lock.yaml` or `Cargo.lock` unless updating dependencies is the purpose of the PR
|
||||
- **AGPL-3.0**: This project is AGPL-licensed. Derivatives must be open source with the same license
|
||||
- Translations: Any UI text change must be reflected in all 9 locale files (`src/i18n/locales/`)
|
||||
- Tauri commands: If you modify Tauri commands, the `test_no_unused_tauri_commands` test will catch unused ones
|
||||
- No hardcoded colors: Use theme CSS variables (see `src/lib/themes.ts`), never Tailwind color classes like `text-red-500`
|
||||
- No lock file changes: Don't update `pnpm-lock.yaml` or `Cargo.lock` unless updating dependencies is the purpose of the PR
|
||||
- AGPL-3.0: This project is AGPL-licensed. Derivatives must be open source with the same license
|
||||
|
||||
## Pull Request Guidelines
|
||||
|
||||
@@ -88,13 +98,13 @@ codeql database analyze /tmp/codeql-rust --format=sarifv2.1.0 --output=/tmp/rust
|
||||
|
||||
## Architecture
|
||||
|
||||
- **Frontend**: Next.js (React), `src/`
|
||||
- **Backend**: Tauri (Rust), `src-tauri/src/`
|
||||
- **Proxy Worker**: Detached process for proxy tunneling, `src-tauri/src/bin/proxy_server.rs`
|
||||
- **Sync**: Cloud sync via S3-compatible storage, `src-tauri/src/sync/`, `donut-sync/`
|
||||
- **Browsers**: Wayfern (Chromium-based anti-detect)
|
||||
- Frontend: Next.js (React), `src/`
|
||||
- Backend: Tauri (Rust), `src-tauri/src/`
|
||||
- Proxy Worker: Detached process for proxy tunneling, `src-tauri/src/bin/proxy_server.rs`
|
||||
- Sync: Cloud sync via S3-compatible storage, `src-tauri/src/sync/`, `donut-sync/`
|
||||
- Browsers: Wayfern (Chromium-based anti-detect)
|
||||
|
||||
## Getting Help
|
||||
|
||||
- **Issues**: Bug reports and feature requests
|
||||
- **Discussions**: Questions and general discussion
|
||||
- Issues: Bug reports and feature requests
|
||||
- Discussions: Questions and general discussion
|
||||
|
||||
Reference in New Issue
Block a user