docs: standardize install order for tccutil-rs#8
Conversation
|
Warning Rate limit exceeded
⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. 📝 WalkthroughWalkthroughThis PR updates the installation documentation and introduces an automated install script for tccutil-rs. The README now features a Homebrew-based installation method and a renamed "Direct install" section. A new shell script handles installation from GitHub Releases with architecture detection, checksum verification, and binary placement. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~15 minutes Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (2)
README.md (2)
35-36: Optional: note sudo may be required for /usr/local/bin.Some macOS setups don’t allow non‑admin writes there.
✍️ Doc tweak suggestion
cargo build --release -install -m 0755 target/release/tccutil-rs /usr/local/bin/tccutil-rs +# Use sudo if /usr/local/bin is not writable +sudo install -m 0755 target/release/tccutil-rs /usr/local/bin/tccutil-rs🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@README.md` around lines 35 - 36, Update the README.md where the install command "install -m 0755 target/release/tccutil-rs /usr/local/bin/tccutil-rs" is shown to include an optional note that sudo may be required for writing to /usr/local/bin on some macOS systems; add a short parenthetical or sentence after that command advising users to run the command with sudo if they encounter permission errors and/or to use an alternative install location if they lack admin rights.
25-29: Consider adding a pinned‑version example and fail‑fast curl.This keeps installs reproducible and surfaces download failures immediately.
✍️ Doc tweak suggestion
-```sh -curl -sSL https://raw.githubusercontent.com/uinaf/tccutil/main/scripts/install.sh | sh -``` +```sh +curl -fsSL https://raw.githubusercontent.com/uinaf/tccutil/main/scripts/install.sh | sh + +# Pinned version example: +# curl -fsSL https://raw.githubusercontent.com/uinaf/tccutil/main/scripts/install.sh | sh -s -- v0.1.1 +```🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@README.md` around lines 25 - 29, Update the "Direct install" curl example in README to use fail‑fast curl by adding the -f flag (change curl -sSL to curl -fsSL) and add a second example showing a pinned release invocation (e.g., piping to sh -s -- <version>) so users can reproduce installs; modify the "Direct install" block that contains the curl command to include both the -fsSL form and the pinned‑version example.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@scripts/install.sh`:
- Around line 74-80: The checksum verification pipeline can silently succeed if
grep finds no match because POSIX sh lacks pipefail; update scripts/install.sh
to explicitly ensure a matching checksum line exists before invoking shasum:
after changing to "$tmp_dir", use grep -q " ${asset}$" checksums.txt and if
that returns non-zero call error "checksum entry missing for $asset", then pipe
the matched line to shasum -a 256 -c - (or run shasum -a 256 -c on the extracted
line) and on any non-zero exit call error "checksum verification failed";
reference the variables/commands asset, tmp_dir, checksums.txt, grep and shasum
when making the change.
---
Nitpick comments:
In `@README.md`:
- Around line 35-36: Update the README.md where the install command "install -m
0755 target/release/tccutil-rs /usr/local/bin/tccutil-rs" is shown to include an
optional note that sudo may be required for writing to /usr/local/bin on some
macOS systems; add a short parenthetical or sentence after that command advising
users to run the command with sudo if they encounter permission errors and/or to
use an alternative install location if they lack admin rights.
- Around line 25-29: Update the "Direct install" curl example in README to use
fail‑fast curl by adding the -f flag (change curl -sSL to curl -fsSL) and add a
second example showing a pinned release invocation (e.g., piping to sh -s --
<version>) so users can reproduce installs; modify the "Direct install" block
that contains the curl command to include both the -fsSL form and the
pinned‑version example.
Summary
Standardize direct install usage to a single script path and remove the duplicate root installer.
Changes
install.shfrom the repo.scripts/install.shas the only direct install script.curl -sSL https://raw.githubusercontent.com/uinaf/tccutil/main/scripts/install.sh | shValidation
git ls-tree -r --name-only HEAD | rg '^install\.sh$|^scripts/install\.sh$'sh -n scripts/install.shLinked Issues