fix(build): Use shared Rust target directory by default (fixes #2442). - #2459
fix(build): Use shared Rust target directory by default (fixes #2442).#2459junhaoliao wants to merge 1 commit into
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
WalkthroughCargo now stores Rust build outputs in ChangesCargo build configuration
Estimated code review effort: 1 (Trivial) | ~2 minutes Possibly related issues
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ 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 |
|
I assume this PR is intended to have Cargo invocations outside the CLP toolchain environment use the same target directory as the CLP-managed toolchain. That being said, if a user runs: G_BUILD_DIR=/some/other/location task <some_rust_task>the If supporting custom Anyway, there's no perfect way to make cargo default to the CLP-installed toolchain without requiring some prerequisite setup. |
Description
Fixes #2442.
Cargo commands launched outside the Taskfile environment, including IDE language servers and coding agents, currently fall back to the repository-local
target/directory and duplicate artifacts already stored underbuild/rust-targets.Restore
build/rust-targetsas Cargo's repository default in.cargo/config.toml. The generated toolchain environment continues to exportCARGO_TARGET_DIRfromG_RUST_BUILD_DIR, so customG_BUILD_DIRvalues still take precedence over the default.Checklist
Validation performed
Summary by CodeRabbit