gpui-fast: Command for Claude Code

.claude/commands/update-upstream.md

update-upstream is a command for Claude Code from longbridge/gpui-fast. It costs 26 tokens per session (1,568 once invoked), scanned A, original, Apache-2.0.

A checklist for bringing code from a newer commit of the Zed editor into the gpui-fast project. It covers fetching the upstream code, comparing changes, importing them, adapting differences, checking the result, and preparing a pull request.

In plain words
What is it for?
Use it when updating gpui-fast to a selected or current zed-industries/zed commit.
Why use it?
Upstream synchronization involves more than copying files: dependencies, removed code, and project-specific differences can be missed. This gives the update a defined sequence of checks.

Command for Claude Code

Written for Claude Code: argument-hint in frontmatter.

This is longbridge/gpui-fast's own configuration. It tells Claude Code how to work on gpui-fast itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything gpui-fast configures →

Reuse

Borrowing it

Nothing to install: this file belongs to longbridge/gpui-fast. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/longbridge/gpui-fast/main/.claude/commands/update-upstream.md
Clone the repo
git clone --depth 1 https://github.com/longbridge/gpui-fast

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for update-upstream

README.md
[![agentmods](https://agentmods.dev/badge/commands/longbridge/gpui-fast/update-upstream/github.svg)](https://agentmods.dev/commands/longbridge/gpui-fast/update-upstream)
Your own site
<a href="https://agentmods.dev/commands/longbridge/gpui-fast/update-upstream"><img src="https://agentmods.dev/badge/commands/longbridge/gpui-fast/update-upstream/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for update-upstream

Your own site · 80×15
<a href="https://agentmods.dev/commands/longbridge/gpui-fast/update-upstream"><img src="https://agentmods.dev/badge/commands/longbridge/gpui-fast/update-upstream.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 26 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,568 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00026 $0.01568
Opus 5.5 $0.00010 $0.00627
Sonnet 5.5 $0.00005 $0.00314
Haiku 4.5 $0.00003 $0.00157

Measured 5d ago against content hash 31fbb5faa47c, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

update-upstream scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/update-upstream.md · 116 lines

How it starts

The opening of the file, as written. The whole thing — 116 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Take a newer upstream zed into gpui-fast, following "Syncing with upstream" in docs/upstream-sync.md. Read that document and UPSTREAM first; they are the rules, this is the checklist. Target zed commit: $ARGUMENTS (empty means the current main of zed-industries/zed).

0. Prepare

  • Working tree must be clean; git fetch origin. Never commit to main.
  • A zed checkout lives at ~/github/zed. If missing: git clone --filter=blob:none https://github.com/zed-industries/zed ~/github/zed. Otherwise git -C ~/github/zed fetch origin.
  • Resolve the target to a full hash (NEW). Read zed_commit (OLD) and import_commit (OLD_VENDOR) from UPSTREAM. Report how many zed commits lie between OLD and NEW and which touch the tracked directories (git -C ~/github/zed log --oneline OLD..NEW -- <tracked dirs>).
  • Check whether zed now has crates that tracked crates depend on but UPSTREAM doesn't track (new path/workspace = true deps in their Cargo.tomls), or tracked crates zed deleted.
  • Check whether zed merged window composition (zed#62379). If it did, the sync replaces fast::composition with upstream's version (see "Where our API differs from upstream's"); stop and confirm the plan with the user before doing that.

1. Vendor commit (upstream code only)

Keep zed's commits: the vendor branch gets one commit per zed commit, not a single squashed import.

  • If zed added crates we now need, add them to tracked in UPSTREAM first (uncommitted is fine; the script reads the working tree's UPSTREAM). Leave crates zed deleted in tracked for the import, so their deletion is replayed; drop them from tracked in step 4.
  • Run script/import-upstream --zed ~/github/zed NEW. Starting at OLD_VENDOR, it creates branch upstream/zed-<short NEW> in a worktree (../gpui-fast-upstream-<short NEW>) and replays every zed commit in OLD..NEW that touches a tracked directory, limited to those directories, with its original author, committer, dates and message plus an Upstream-commit: trailer. It fails unless every tracked directory then matches zed at NEW. Its last line prints the new vendor commit.
  • Nothing of ours goes on this branch; root Cargo.toml/Cargo.lock are ours and change in step 2.

Read the full file on GitHub · 116 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago Changed · +10 lines 31fbb5faa47c
  2. 1mo ago First seen · 106 lines · 26 tokens per session scan A 2bbe28fd7e82

Subscribe to this mod's changes

update-upstream is a command published in the GitHub repository longbridge/gpui-fast (393 stars, last pushed yesterday), licensed Apache-2.0. It adds 26 tokens to every session and 1,568 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-01.

Related

update-upstream compared with commands from other repositories

update-upstream next to 6 commands from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
update-upstreamlongbridge/gpui-fastCommand393yesterdayApache-2.0A26Claude Code
merge-conflict-analysisrjmurillo/ai-agentsCommand49yesterdayMITA0GitHub Copilot
release-notesOpenHands/extensionsCommand176yesterdayMITA44Claude Code
commitechoVic/blade-codeCommand18124d agoMITA8Claude Code
repo-audittractorjuice/arc-kitCommand2.3k2d agononeA29Claude Code
propsmill/infrahub-mcpCommand10yesterdayApache-2.0A18Claude Code
codex-reviewoalders/kitchen-sinkCommand53d agoMITA41Claude Code