Thanks for sending changes.
git clone git@github.com:uinaf/tccutil-rs.git
cd tccutil
cargo build --releaseBinary lands at target/release/tccutil-rs. Cargo auto-installs the pinned toolchain on first run.
Invoke the binary directly while iterating:
cargo run -- list --user
cargo run -- infoRead commands work without privileges. Write commands (grant, revoke, enable, disable, reset) need either the user database (no sudo) or sudo for the system database. See SIP limitations in the README.
One entrypoint runs everything CI runs:
scripts/verify.shIt runs cargo fmt --check, cargo clippy -- -D warnings, and cargo test — the same gates as the CI Verify job.
Optional pre-push gate that calls the same script:
scripts/setup-hooks.sh # one-time, points git at .git-hooks/After install, every git push runs scripts/verify.sh and fails the push if anything goes red.
- Conventional commits —
feat:,fix:,test:,docs:,chore:. CI does not enforce; reviewers do. - No
unsafeoutside the singlelibc::geteuid()call insrc/tcc.rs. - Errors return
Result<_, TccError>. Add a new variant when an error doesn't fit the existing kinds. - Table output in
src/main.rsdoes manual ANSI-aware padding. If you touch it, runtccutil-rs listagainst a real TCC.db to eyeball alignment. - Integration tests in
tests/integration.rsexec the real binary viaCARGO_BIN_EXE_tccutil-rs. Unit tests insrc/tcc.rsround-trip real SQLite viatempfile. No mocks.
Push-to-main, semantic-release driven. Mirrors the uinaf/react-json-logic setup.
When a feat: or fix: lands on main, the release job in .github/workflows/ci.yml runs after verify passes and:
semantic-releaseanalyzes commits since the lastv*tag and decides the next version.scripts/release-prepare.shbumpsCargo.toml+Cargo.lockto the new version (via@semantic-release/exec).@semantic-release/gitcommits those files back tomainaschore(release): <version> [skip ci](the[skip ci]keeps the bump from re-triggering the pipeline).@semantic-release/githubcreates thev<version>tag and the GitHub Release with the changelog as the body.- macOS dual-arch build runs in the same job, attaching tarballs +
checksums.txtto the new Release. dawidd6/action-homebrew-bump-formulaopens a PR againstuinaf/homebrew-tapbumpingFormula/tccutil-rs.rb.
Bot identity is glitch418x (set inside the semantic-release step's env:).
Required secrets on this repo:
GITHUB_TOKEN— provided automatically. Used by semantic-release for the bump-back commit, tag, and Release.TAP_GITHUB_TOKEN— fine-grained PAT forglitch418xwithcontents: writeandpull-requests: writeonuinaf/homebrew-tap. The defaultGITHUB_TOKENonly has scope on this repo.
chore: / docs: / refactor: commits do not bump the version on their own — land them alongside a feat: or fix: if you want them in a release. feat!: / BREAKING CHANGE: bumps the major.
- Keep changes focused — a single concern per PR.
- Add or update behavior-covering tests when behavior changes.
- Run
scripts/verify.shbefore pushing. - Include the most useful evidence for the kind of change:
- Command output for new flags or subcommands
- Before-and-after for output formatting changes
- SQLite schema notes when the digest set in
KNOWN_DIGESTSchanges - Rollout notes when touching write paths or root checks