feat: auto-provision runner toolchains#66
Conversation
Peyton-Spencer
left a comment
There was a problem hiding this comment.
Good first pass. Architecture is clean — dependency injection on ToolProvisioningService makes it testable, ToolDetector enum is a nice pattern, and the package name normalization whitelist blocks shell metacharacters.
One minor security note (not blocking):
In ToolProvisioningService.swift, isInstalled() uses string interpolation into a shell command:
let result = try await runCommand("/bin/bash", ["-lc", "command -v \(package)"])The normalize() whitelist ([a-z0-9@+._-]) prevents injection, so this is safe in practice. But if this ever gets refactored, the interpolation pattern could become a risk. Consider using ["/opt/homebrew/bin/\(package)", "/usr/local/bin/\(package)"] path checks exclusively (which you already do first), and dropping the command -v fallback — or at least adding a comment noting the safety invariant.
Everything else looks solid. Will merge when CI is green.
Add the explicit return required by Swift in ToolProvisioningSettings.normalize() so the tool-provisioning build passes. This keeps PR #66 aligned with the existing package normalization behavior without changing the planned feature scope. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
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. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (6)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Install gh up front for new runners, detect common language toolchains from repository metadata, and support extra Homebrew packages via settings. This keeps non-isolated and dedicated-user runners closer to a ready-to-run CI environment without per-workflow setup. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add the explicit return required by Swift in ToolProvisioningSettings.normalize() so the tool-provisioning build passes. This keeps PR #66 aligned with the existing package normalization behavior without changing the planned feature scope. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
96460b4 to
5f133a3
Compare
|
🎉 This PR is included in version 1.14.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
Summary
ghbefore repo validation, then detect common language toolchains from root repo metadata when creating new runnerssettings.tools.extraPackagesconfig plus settings UI so users can request extra Homebrew packages for future runnersghpath detection with focused unit testsTesting
git diff --checkswift test(not runnable in this container:swift: command not found)Notes