chore: add Amp orb setup/resume scripts - #334
Merged
Merged
Conversation
Give future orbs a fast, idempotent Rust toolchain path and ignore local portal files so agents can build in-cli without manual rustup. Amp-Thread-ID: https://ampcode.com/threads/T-01a0a631-f6de-735d-b395-b45d281f927e Co-authored-by: Max Carter <undivisible@vk.com>
|
Capy couldn't review this pull request because Max's workspace is out of credits, add credits or enable auto-reload to resume automatic reviews. |
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_90f015a1-5b1b-4942-854a-1ad8085f8fab) |
|
Tick the box to add this pull request to the merge queue (same as
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
Fresh Amp orbs did not have a committed
.agents/setup/.agents/resume, so agents had to install rustup by hand.What
.agents/setup(apt packages if missing, rustup stable + rustfmt/clippy/rust-src,cargo fetch --lockedfor in-cli)..agents/resumethat only checks rustc/cargo..amp/portals/.Cold setup ~19s in this orb; warm setup ~0.3s after PATH includes
~/.cargo/bin. Resume ~0s.Does not change compiler behavior. Safe to merge independently of the package-install security PR.
Note
Low Risk
Developer-environment and gitignore-only changes; no application runtime, auth, or compiler behavior changes.
Overview
Adds Amp orb lifecycle scripts so fresh environments get Rust without manual rustup steps.
.agents/setupis an idempotent inauguration script: installs missing apt deps (build-essential,pkg-config,curl,ca-certificates), installs/configures rustup stable withrustfmt,clippy, andrust-src, appends a one-time.bash_profilehook to source~/.cargo/env, and runscargo fetch --lockedforin-cliwhenCargo.lockexists. Steps are timed via a smallstep()helper..agents/resumeis a fast path that only sources cargo env and fails fast ifrustc/cargoare missing (directing users to run setup). It does not install packages..gitignorenow ignores local.amp/portals/.Reviewed by Cursor Bugbot for commit 8674283. Configure here.