chore(cua-driver-rs)(install): make Rust the default backend - #1768
Conversation
Flip the install.sh dispatcher default from the Swift macOS implementation to the cross-platform Rust implementation: USE_RUST_BACKEND now defaults to 1, so a plain `curl … | bash` installs the Rust backend on every platform. Swift becomes opt-in via --backend=swift (macOS only). The existing non-macOS guard is retained — an explicit --backend=swift on a non-macOS host still transparently falls back to Rust. Header/usage/inline comments updated to match; --backend=rust is now the explicit-default no-op. No docs change: no cua-driver docs page references the backend default or the --backend flags. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
📝 WalkthroughWalkthroughThe installation script shifts its default backend from Swift to Rust, upgrades ChangesBackend selection and fallback logic
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 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 |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@libs/cua-driver/scripts/install.sh`:
- Around line 65-67: Update the outdated comments in the install.sh script to
reflect that USE_RUST_BACKEND=1 makes the Rust backend the default;
specifically, change the earlier block that currently states Swift is the
default (Lines 15-21) to say Rust is the default and Swift/macOS is opt-in via
--backend=swift, and also change the later block (Lines 57-59) which implies
Rust only runs after --backend=rust to instead explain that Rust is used by
default and that --backend=rust is redundant on non-macOS while --backend=swift
forces the Swift backend on macOS; reference the USE_RUST_BACKEND variable and
the CLI flags --backend=swift / --backend=rust when updating the wording.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 75598018-4c69-4b53-95fb-18b949ae2de4
📒 Files selected for processing (1)
libs/cua-driver/scripts/install.sh
| # Default backend is the cross-platform Rust implementation. The Swift macOS | ||
| # implementation is opt-in via --backend=swift, and only runs on macOS. | ||
| USE_RUST_BACKEND=1 |
There was a problem hiding this comment.
Update the remaining script comments to match the new default.
With USE_RUST_BACKEND=1 here, Lines 15-21 and Lines 57-59 are now stale: they still describe Swift as the default and say Rust delegation only happens after --backend=rust or on non-macOS. That leaves the file with conflicting instructions.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@libs/cua-driver/scripts/install.sh` around lines 65 - 67, Update the outdated
comments in the install.sh script to reflect that USE_RUST_BACKEND=1 makes the
Rust backend the default; specifically, change the earlier block that currently
states Swift is the default (Lines 15-21) to say Rust is the default and
Swift/macOS is opt-in via --backend=swift, and also change the later block
(Lines 57-59) which implies Rust only runs after --backend=rust to instead
explain that Rust is used by default and that --backend=rust is redundant on
non-macOS while --backend=swift forces the Swift backend on macOS; reference the
USE_RUST_BACKEND variable and the CLI flags --backend=swift / --backend=rust
when updating the wording.
What
Flip the
install.shbackend dispatcher default from the Swift macOS implementation to the cross-platform Rust implementation.USE_RUST_BACKENDnow defaults to1, so a plaincurl … | bashinstalls the Rust backend on every platform.--backend=swift(macOS only).--backend=swifton a non-macOS host still transparently falls back to Rust.--backend=rustis now the explicit-default no-op.Why
Switches the default install back to the Rust driver, which is the actively-developed, cross-platform implementation.
Notes
bash -nsyntax check passes.install.ps1) is unaffected — Windows is Rust-only and has no Swift default.--backendflags.Separate PR
Filed on its own, separate from the agent-cursor registry fix (#1769), per request.
🤖 Generated with Claude Code
Summary by CodeRabbit