| 1 |
# Contributing |
| 2 |
|
| 3 |
Solo project. External contributions aren't accepted yet; the design is still |
| 4 |
moving. When that changes this file will grow. |
| 5 |
|
| 6 |
## Working in this repo |
| 7 |
|
| 8 |
- Design and load-bearing decisions live in `~/Wiki/shop-*.md`, not here. |
| 9 |
- Work backlog is in GoingsOn (project `shop`), not `todo.md`. |
| 10 |
- Rust 2024 edition, latest stable toolchain. |
| 11 |
- `cargo deny check` must pass before commit. No GPL/LGPL/AGPL, ever. |
| 12 |
- `cargo fmt` + `cargo clippy --all-targets` clean. |
| 13 |
- Commits are concise, imperative, no emoji. |
| 14 |
- Build prerequisites are in the README's Building section. A dependency that |
| 15 |
links a new system library changes that section, and it changes Alloy's |
| 16 |
Containerfile too: Alloy builds shop from source at a pinned revision, so a |
| 17 |
library added here breaks its image at the next `SHOP_REV` move. Say so in the |
| 18 |
commit. |
| 19 |
|
| 20 |
## Adding a component crate |
| 21 |
|
| 22 |
Internal crates are scaffolded when they start, not up front: |
| 23 |
|
| 24 |
``` |
| 25 |
cargo new --lib crates/<name> |
| 26 |
``` |
| 27 |
|
| 28 |
Then add it to `Cargo.toml`'s `[workspace] members`, add the `[lints] |
| 29 |
workspace = true` block, and inherit `edition`/`rust-version`/`authors`/ |
| 30 |
`repository`/`license` from `[workspace.package]`. |
| 31 |
|
| 32 |
## Attribution |
| 33 |
|
| 34 |
Files adapted from external sources (rio, alacritty, foot, etc.) get a |
| 35 |
header comment naming the source, its license, and the commit SHA or version |
| 36 |
tag. See `ATTRIBUTIONS.md` for the full list. |
| 37 |
|