Skip to content

[common-skills migration] Add warp-skills install/remove wrappers + downstream lock refresh - #37

Draft
vkodithala wants to merge 6 commits into
mainfrom
oz/warp-skills-lock-automation
Draft

[common-skills migration] Add warp-skills install/remove wrappers + downstream lock refresh#37
vkodithala wants to merge 6 commits into
mainfrom
oz/warp-skills-lock-automation

Conversation

@vkodithala

@vkodithala vkodithala commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

Summary

Extends the shared common-skills tooling so that the internal warp-skills repo is installed and kept in sync the same way common skills are.

This is part of a series of changes intended to make common-skills plug-and-play with any repo (which should be particularly helpful for enterprises we're working with, like Narwhal) and present a public-facing library of skills curated by Warp. The end-goal here is to make our common skills library akin to something like this, rather than a set of skills specific to our client/server. Here's some more context on the motivation behind this change: https://warpdev.slack.com/archives/C08KTPNQN65/p1781557027648009.

This PR lets warp and warp-server drop their vendored install_warp_skills copies and call a shared wrapper through the existing resolve_common_skills resolver. Related client and server PRs:

Changes

Installer

  • install_common_skills gains --source, --lock-file, --label, and --best-effort, so one code path can drive any skill set. Defaults reproduce the current common-skills behavior exactly.
    • Non-default locks install through a temp dir (lock copied to skills-lock.json) before experimental_install, then skill dirs are copied into the target — the same approach the global path already uses.
    • --best-effort turns a missing lock or no repo access into a one-line notice + exit 0, sets GIT_TERMINAL_PROMPT=0 so an inaccessible source fails fast without a credential prompt, and skips the interactive upstream-update check. It does not relax the naming guard below.
  • The project-vs-global exclusivity check applies to every set, including warp-skills: a skill name found in both .agents/skills and ~/.agents/skills fails the install rather than silently landing in two places. Since warp-skills and common skills use distinct names, this also surfaces any accidental naming collision between the two sets.
  • install_warp_skills / remove_warp_skills are thin wrappers that call the parametrized scripts with the warp-skills source/lock/label and --best-effort; they honor --skip-warp-skills / WARP_SKIP_WARP_SKILLS_INSTALL=1.
  • Stamp filenames are label-scoped (common-skills-lock.hash, warp-skills-lock.hash) so the two sets don't collide.

Downstream lock automation

  • update_common_skills_lock gains --source/--lock-file, and a single parametrized matrix job in update-downstream-skill-locks.yml refreshes both skills-lock.json and warp-skills-lock.json in warp/warp-server, opening a lockfile-only PR per changed lock. A consumer that doesn't yet carry a given lock is skipped rather than failing the job. The workflow keeps using the existing COMMON_SKILLS_SYNC_APP_ID variable and COMMON_SKILLS_SYNC_APP_PRIVATE_KEY secret — no repo-settings changes required.

Testing

Exercised the shared scripts via the resolver chain (WARP_COMMON_SKILLS_SCRIPTS_DIR → this branch's scripts/) and the remote fetch path (WARP_COMMON_SKILLS_REF):

  • Backward-compat (common skills): install_common_skills with defaults, in an isolated HOME, installs all 20 common skills, verifies (… match skills-lock.json), and writes common-skills-lock.hash. Project/global behavior is unchanged.
  • warp-skills install via the wrapper (against a ref that carries the content) installs the locked skills, verifies (… match warp-skills-lock.json), writes warp-skills-lock.hash, and is idempotent under --if-needed.
  • Best-effort / opt-out: --skip-warp-skills, WARP_SKIP_WARP_SKILLS_INSTALL=1, and a missing lock all exit 0 with a clean notice; an inaccessible source fails fast (no credential prompt) and skips.
  • Removal: remove_warp_skills removes the locked skills and the stamp.

Note: the downstream warp-skills-lock.json currently pins ref: main, but the warp-skills content is not on main yet, so a real install no-ops there until the lock is regenerated against the finalized branch (see the client/server PRs).

Follow-up

  • Once warp-skills content lands on main, regenerate warp-skills-lock.json (update_common_skills_lock --source warpdotdev/warp-skills --lock-file warp-skills-lock.json); the wrapper is lock-driven and needs no change.

Plan: https://staging.warp.dev/drive/notebook/R4ucMiSKpclPGJXzpoFu4t

This PR was generated with _Oz._

Add an update-warp-skills-lockfile job mirroring the existing
common-skills lock job. It regenerates warp-skills-lock.json in the
downstream consumers (warp, warp-server) from warpdotdev/warp-skills
using the pinned skills CLI, opens a downstream PR when the lock
changes, requests the source author as reviewer, and enables squash
auto-merge. The refresh is best-effort: it skips repos that have no
warp-skills-lock.json yet and skips on CLI failure without failing the
workflow. The existing common-skills flow is left unchanged.

Co-Authored-By: Oz <oz-agent@warp.dev>
@vkodithala
vkodithala marked this pull request as ready for review June 30, 2026 22:17
@oz-for-oss

oz-for-oss Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

@vkodithala

I'm starting a first review of this pull request.

You can view the conversation on Warp.

I completed the review and no human review was requested for this pull request.

Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).

Powered by Oz

@vkodithala vkodithala changed the title Refresh downstream warp-skills locks from warp-skills (Phase 2) [common-skills migration] Refresh downstream warp-skills locks from warp-skills Jun 30, 2026

@oz-for-oss oz-for-oss Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overview

This PR adds a second downstream GitHub Actions job that refreshes warp-skills-lock.json for warpdotdev/warp and warpdotdev/warp-server using the pinned skills CLI, while leaving the existing common-skills lock refresh flow unchanged.

Concerns

  • No blocking concerns found in the annotated diff.
  • Supplemental security review found no security issues requiring comments.
  • No approved or repository spec context was provided, so spec-drift review was not applicable.

Verdict

Found: 0 critical, 0 important, 0 suggestions

Approve

Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).

Powered by Oz

vkodithala and others added 2 commits June 30, 2026 22:44
- Generalize scripts/update_common_skills_lock with --source/--lock-file
  (defaults preserved: warpdotdev/common-skills + skills-lock.json) so the
  warp-skills lock refresh is a one-liner instead of inlined logic.
- Collapse the two jobs into a single matrixed job (2 repos x 2 lock
  variants) sharing resolve-source-PR, app token, checkout, create-PR,
  request-reviewer, and auto-merge steps.
- Rename Actions var/secret COMMON_SKILLS_SYNC_APP_ID/_PRIVATE_KEY to
  SKILLS_SYNC_APP_ID/_PRIVATE_KEY (now syncs both locks).

Co-Authored-By: Oz <oz-agent@warp.dev>
Parametrize install_common_skills and remove_common_skills with --source,
--lock-file, and --label so one code path can drive any skill set, plus a
--best-effort mode (friendly skip on missing lock / no access, no credential
prompt, and bypass of the project-vs-global dedupe scoped to a single set).
Add install_warp_skills and remove_warp_skills thin wrappers targeting
warpdotdev/warp-skills (warp-skills-lock.json). Defaults keep the existing
common-skills behavior unchanged.

Co-Authored-By: Oz <oz-agent@warp.dev>
@vkodithala vkodithala changed the title [common-skills migration] Refresh downstream warp-skills locks from warp-skills [common-skills migration] Add warp-skills install/remove wrappers + downstream lock refresh Jul 1, 2026

@vkodithala vkodithala left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Took a glance; few small comments that we should probably address.

Comment thread .github/workflows/update-downstream-skill-locks.yml Outdated
Comment thread .github/workflows/update-downstream-skill-locks.yml
Comment thread scripts/README.md Outdated
Comment thread scripts/install_common_skills Outdated
vkodithala and others added 3 commits July 1, 2026 18:19
- Remove the change-specific 'Renamed from ...' note from the README app-id
  section (recoverable via git blame).
- Reword the best-effort exclusivity-bypass docs/comment to explain it as a
  within-set guard and note that warp-skills should avoid reusing common-skill
  names.

Co-Authored-By: Oz <oz-agent@warp.dev>
Revert the app-id variable and private-key secret back to
COMMON_SKILLS_SYNC_APP_ID / COMMON_SKILLS_SYNC_APP_PRIVATE_KEY so the existing
repo secret and variable keep working without a rename (GitHub secrets are
write-only and can't be renamed from the UI).

Co-Authored-By: Oz <oz-agent@warp.dev>
- Remove the best-effort exclusivity bypass so the project-vs-global check runs
  for every set, surfacing any warp-skills/common-skills name collision instead
  of silently coexisting.
- Add explanatory comments to the downstream workflow (missing-lock skip, lock
  diff check) and to install_common_skills (best-effort install failure,
  missing-lock adoption behavior).
- Clarify the --best-effort usage text.
- install_warp_skills: forward args as-is now that --skip-warp-skills exits early.

Co-Authored-By: Oz <oz-agent@warp.dev>
@vkodithala
vkodithala requested a review from vorporeal July 2, 2026 18:47
@vorporeal
vorporeal removed their request for review July 2, 2026 19:32
@vkodithala
vkodithala requested a review from johnturcoo July 2, 2026 20:18

@johnturcoo johnturcoo left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!!

@vkodithala
vkodithala marked this pull request as draft July 31, 2026 15:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants