Skip to content

Commit f7c52ba

Browse files
algattikCopilot
andcommitted
fix(skills): use GitHub CLI for RPI bootstrap
- replace the custom downloader with pinned gh skill installs - retain the explicit eight-skill allowlist and workflow contract 🔧 - Generated by Copilot Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent 8252729 commit f7c52ba

9 files changed

Lines changed: 54 additions & 732 deletions

File tree

.github/copilot-instructions.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -332,15 +332,15 @@ The weekly `copilot-setup-steps.yml` cron and `Test-BinaryFreshness.ps1` weekly
332332

333333
### Cloud-Agent RPI Skills
334334

335-
The `Bootstrap hve-core RPI skills` step in `copilot-setup-steps.yml` runs **outside** the cloud-agent firewall and downloads the complete RPI skill suite from a pinned `microsoft/hve-core` commit into immediate subdirectories of `.github/skills/`.
335+
The `Bootstrap hve-core RPI skills` step in `copilot-setup-steps.yml` runs **outside** the cloud-agent firewall and uses `gh skill install` to download the complete RPI skill suite from a pinned `microsoft/hve-core` commit into immediate subdirectories of `.github/skills/`.
336336

337-
The generated `.github/skills/rpi-*/` directories are gitignored and excluded from repository Markdown linting. The standalone bootstrap script stages downloads before installation, accepts Markdown blobs only, verifies each pinned Git blob SHA, requires all eight skill entry points, rejects unexpected top-level content, and records the resolved commit, file paths, and blob SHAs in `.github/skills/.rpi-audit.json`. Bootstrap failure is fatal because no local fallback provides these workflows.
337+
The generated `.github/skills/rpi-*/` directories are gitignored and excluded from repository Markdown linting. The setup step names all eight allowed skill paths explicitly, pins every installation to the reviewed commit, and relies on the GitHub CLI to preserve each skill's references and templates and inject its source commit and tree metadata into `SKILL.md`. Bootstrap failure is fatal because no local fallback provides these workflows.
338338

339339
The cloud agent discovers the `rpi-quick`, `rpi-research`, `rpi-plan`, `rpi-implement`, and `rpi-review` workflows directly from their `SKILL.md` files. The bootstrap also preserves `rpi-challenger`, `rpi-plan-critique`, `rpi-walkthrough`, and every bundled reference and template.
340340

341-
The current immutable commit predates a published hve-core release containing the skill-forward layout. Prefer a released commit on upgrades; when none exists, review the complete upstream commit and tree before changing `UPSTREAM_REF`.
341+
The current immutable commit predates a published hve-core release containing the skill-forward layout. Prefer a released commit on upgrades; when none exists, review the complete upstream commit and tree before changing `RPI_SKILLS_REF`.
342342

343-
Before starting RPI work, verify `.github/skills/.rpi-audit.json` exists and contains the expected pinned `resolved_sha`; otherwise stop with a bootstrap failure. Treat `.copilot-tracking/` files as session scratch because the directory is gitignored.
343+
Before starting RPI work, verify each required `.github/skills/rpi-*/SKILL.md` exists and its `metadata.github-pinned` value matches `RPI_SKILLS_REF`; otherwise stop with a bootstrap failure. Treat `.copilot-tracking/` files as session scratch because the directory is gitignored.
344344

345345
In cloud-agent PR work, persist each completed RPI phase as a PR comment and maintain an `RPI Artifact Index` in the PR description with the phase comment links and resolved upstream SHA. If PR write tools are unavailable, include the complete phase artifacts in the final response rather than claiming durable persistence.
346346

.github/instructions/shell-scripts.instructions.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -100,10 +100,6 @@ info "Operation complete"
100100

101101
<!-- <important-conventions> -->
102102

103-
Standalone trust-bootstrap scripts under `scripts/ci/` may omit `common.sh`,
104-
argument parsing, `--config-preview`, and deployment summaries when sourcing
105-
repository helpers would widen the bootstrap trust boundary.
106-
107103
**Arguments:**
108104

109105
- Short: `-h`, `-t` | Long: `--help`, `--tf-dir`

.github/workflows/copilot-setup-steps.yml

Lines changed: 20 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,9 @@ on:
1414
push:
1515
paths:
1616
- .github/workflows/copilot-setup-steps.yml
17-
- scripts/ci/bootstrap-hve-core-rpi-skills.sh
1817
pull_request:
1918
paths:
2019
- .github/workflows/copilot-setup-steps.yml
21-
- scripts/ci/bootstrap-hve-core-rpi-skills.sh
2220
# Weekly drift check: surfaces broken action SHAs, yanked packages, or
2321
# registry outages on a Monday morning instead of mid-Copilot-session.
2422
schedule:
@@ -125,14 +123,30 @@ jobs:
125123

126124
# Run the external-content bootstrap last. A failed Copilot setup step
127125
# skips later steps but still starts the agent with the completed setup.
128-
# UPSTREAM_REF is pinned to the reviewed skill-consolidation commit because
126+
# RPI_SKILLS_REF is pinned to the reviewed skill-consolidation commit because
129127
# no published hve-core release contains this skill layout. Prefer a release
130128
# SHA on future upgrades; otherwise review the commit and complete tree.
131129
- name: Bootstrap hve-core RPI skills
132130
env:
133131
GH_TOKEN: ${{ github.token }}
134132
# microsoft/hve-core derived-files release: hve-core-v3.2.2 (2026-03-23)
135133
HVE_CORE_DERIVED_FILES_REF: e69486a5f809ede45c63c0a31358c12912bd5168
136-
UPSTREAM_REPO: microsoft/hve-core
137-
UPSTREAM_REF: 130ab64338bb77e912e603693672c31f14bc60c6
138-
run: bash scripts/ci/bootstrap-hve-core-rpi-skills.sh
134+
RPI_SKILLS_REF: 130ab64338bb77e912e603693672c31f14bc60c6
135+
run: |
136+
skills=(
137+
rpi-quick
138+
rpi-research
139+
rpi-plan
140+
rpi-implement
141+
rpi-review
142+
rpi-challenger
143+
rpi-plan-critique
144+
rpi-walkthrough
145+
)
146+
for skill in "${skills[@]}"; do
147+
gh skill install microsoft/hve-core \
148+
".github/skills/rpi/${skill}/SKILL.md" \
149+
--pin "$RPI_SKILLS_REF" \
150+
--dir .github/skills \
151+
--force
152+
done

.gitignore

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -466,9 +466,6 @@ venv/
466466
.agent/
467467
.copilot-tracking/
468468
.github/skills/rpi-*/
469-
.github/skills/.rpi-audit.json
470-
.github/skills/.rpi-backup.*
471-
.github/skills/.rpi-staging.*
472469

473470
# Environment-specific deployment artifacts
474471
infrastructure/setup/generated/

.markdownlint-cli2.jsonc

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,6 @@
44
".agent/reviews/**",
55
".copilot-tracking/**",
66
".github/skills/rpi-*/**",
7-
".github/skills/.rpi-backup.*/**",
8-
".github/skills/.rpi-staging.*/**",
97
"venv/**",
108
".venv/**",
119
"**/.venv/**",

docs/reference/copilot-artifacts.md

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ description: >-
44
Inventory and reference for GitHub Copilot agents, instructions, prompts,
55
and skills configured in this repository.
66
author: Microsoft Robotics-AI Team
7-
ms.date: 2026-08-18
7+
ms.date: 2026-09-01
88
ms.topic: reference
99
keywords:
1010
- copilot
@@ -139,15 +139,13 @@ discovery (frontmatter only) → instructions (SKILL.md body) → resources
139139

140140
### rpi-* skill suite
141141

142-
The cloud-agent setup workflow downloads the complete RPI skill suite from
143-
a pinned `microsoft/hve-core` commit into gitignored `.github/skills/rpi-*/`
144-
directories. Each skill is an immediate child of `.github/skills/`, as required
145-
for discovery. Local clones do not contain these skills unless the setup
146-
workflow has provisioned them. Each skill retains its upstream references and
147-
templates, and `.github/skills/.rpi-audit.json` records the resolved commit,
148-
installed file paths, and verified Git blob SHAs. All eight skill entry points
149-
are required. Unexpected top-level content fails bootstrap rather than changing
150-
the installed skill surface implicitly.
142+
The cloud-agent setup workflow uses `gh skill install` to download eight
143+
explicit RPI skill paths from a pinned `microsoft/hve-core` commit into
144+
gitignored `.github/skills/rpi-*/` directories. Each skill is an immediate
145+
child of `.github/skills/`, as required for discovery. Local clones do not
146+
contain these skills unless the setup workflow has provisioned them. Each skill
147+
retains its upstream references and templates, and the GitHub CLI injects the
148+
source commit and tree metadata into its `SKILL.md` front matter.
151149

152150
| Skill | Purpose |
153151
|---------------------|-----------------------------------------------------|

scripts/README.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: Scripts
33
description: CI/CD scripts, shared libraries, linting, security, and Pester tests for the Physical AI Toolchain.
44
author: Microsoft Robotics-AI Team
5-
ms.date: 2026-07-06
5+
ms.date: 2026-09-01
66
ms.topic: reference
77
keywords:
88
- scripts
@@ -49,7 +49,6 @@ CI bootstrap and release automation.
4949

5050
| Script | Purpose |
5151
|---------------------------------------|---------------------------------------------------------|
52-
| `ci/bootstrap-hve-core-rpi-skills.sh` | Provision the verified RPI skill suite for cloud agents |
5352
| `ci/Add-ReleaseVerificationNotes.ps1` | Add release verification notes |
5453
| `ci/Close-ReleaseMilestone.ps1` | Close the milestone associated with a completed release |
5554
| `ci/Install-Gitsign.ps1` | Install the pinned gitsign release |

scripts/ci/bootstrap-hve-core-rpi-skills.sh

Lines changed: 0 additions & 244 deletions
This file was deleted.

0 commit comments

Comments
 (0)