|
| 1 | +# CI & Releases |
| 2 | + |
| 3 | +## Continuous integration |
| 4 | + |
| 5 | +CI runs automatically on every push and pull request via |
| 6 | +`.github/workflows/ci.yml`. |
| 7 | + |
| 8 | +### CI pipeline |
| 9 | + |
| 10 | +| Step | Command | |
| 11 | +|---|---| |
| 12 | +| Checkout | `actions/checkout@v4` | |
| 13 | +| Rust toolchain | `dtolnay/rust-toolchain@stable` | |
| 14 | +| Cache | `Swatinem/rust-cache@v2` | |
| 15 | +| Lint | `cargo clippy --tests -- -D warnings` | |
| 16 | +| Test | `cargo test` | |
| 17 | + |
| 18 | +CI must pass before merging any PR. |
| 19 | + |
| 20 | +## Release pipeline |
| 21 | + |
| 22 | +Releases are triggered by pushing a version tag. The workflow is defined in |
| 23 | +`.github/workflows/release.yml`. |
| 24 | + |
| 25 | +### Triggering a release |
| 26 | + |
| 27 | +```sh |
| 28 | +# 1. Update version in Cargo.toml |
| 29 | +# 2. Commit the version bump |
| 30 | +# 3. Tag and push |
| 31 | +git tag v0.3.0 |
| 32 | +git push origin v0.3.0 |
| 33 | +``` |
| 34 | + |
| 35 | +### Release pipeline steps |
| 36 | + |
| 37 | +1. **Lint & Test** -- same as CI (clippy + tests) |
| 38 | +2. **Build** -- compiles release binaries for 4 targets: |
| 39 | + |
| 40 | +| Target | Runner | Archive | |
| 41 | +|---|---|---| |
| 42 | +| `x86_64-unknown-linux-gnu` | `ubuntu-latest` | `.tar.gz` | |
| 43 | +| `x86_64-apple-darwin` | `macos-latest` | `.tar.gz` | |
| 44 | +| `aarch64-apple-darwin` | `macos-latest` | `.tar.gz` | |
| 45 | +| `x86_64-pc-windows-msvc` | `windows-latest` | `.zip` | |
| 46 | + |
| 47 | +3. **Package** -- creates archives (`tar.gz` on Unix, `zip` on Windows) |
| 48 | +4. **Release** -- creates a GitHub Release with auto-generated changelog and |
| 49 | + attached archives (via `softprops/action-gh-release@v2`) |
| 50 | + |
| 51 | +### Version tags |
| 52 | + |
| 53 | +Use semantic versioning: `v0.1.0`, `v0.2.0`, `v1.0.0`. |
| 54 | + |
| 55 | +Remember to update the `version` field in `Cargo.toml` before creating the tag. |
| 56 | + |
| 57 | +## Install scripts |
| 58 | + |
| 59 | +Two install scripts are provided in the repository root: |
| 60 | + |
| 61 | +### `install.sh` (Linux / macOS) |
| 62 | + |
| 63 | +```sh |
| 64 | +curl -fsSL https://raw.githubusercontent.com/johnsideserf/signal-tui/master/install.sh | bash |
| 65 | +``` |
| 66 | + |
| 67 | +Downloads the latest release binary for the detected platform and checks for |
| 68 | +signal-cli. |
| 69 | + |
| 70 | +### `install.ps1` (Windows) |
| 71 | + |
| 72 | +```powershell |
| 73 | +irm https://raw.githubusercontent.com/johnsideserf/signal-tui/master/install.ps1 | iex |
| 74 | +``` |
| 75 | + |
| 76 | +Downloads the latest Windows release binary and checks for signal-cli. |
| 77 | + |
| 78 | +## Documentation deployment |
| 79 | + |
| 80 | +Documentation is built and deployed via `.github/workflows/docs.yml`. See the |
| 81 | +docs workflow for details on how changes to the `docs/` directory trigger a |
| 82 | +rebuild and deployment to GitHub Pages. |
0 commit comments