on-demand-alpha-build
Skill16 starsChanged 3 years agoMITView on GitHub
Orchestrate an on-demand Azure IoT Operations CLI alpha release from a chosen azure-iot-operations-tests ref: refresh generated release inputs, create a PR, run integration tests after merge, then start the build and wheel-publish workflow.
In this repositoryOne other file it gives its agents.
The file
Show its rules and text
We split this skill into the rules it gives an agent
23 rules. About 0 are common, 16 are distinctive, and 7 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈16
Distinctive · estimate
This author's own choices. Worth a look.
7
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- could be automatic: a setting could enforce it
- Very specific: line 8
Use this workflow for an alpha build requested from a development or release ref.
- Distinctive: line 17
Ask for these at the start.
- Distinctive: line 40
Never commit, push, create a PR, trigger a workflow, approve an environment, or publish merely because preflight succeeded.
- Distinctive: line 42
Never merge the generated PR.
- Very specific: line 43
Never bypass the production environment approval in release_workflow.yml.
- Distinctive: line 47
Never create a GitHub release for an alpha build.
- Distinctive: line 50
Treat the requested tests-repository ref as immutable input.
- Very specific: line 56
Run the full preflight from sync-aio-bicep-templates for the supplied tests-repository ref and release moniker, including its …
- Distinctive: line 64
if a required PR is active and its commit is not an ancestor, stop and ask whether to build from that PR's exact source commit/ref or wait …
- Distinctive: line 69
after compilation and approved redactions, compare the affected generated paths and confirm that each required change survives.
- Very specific: line 75
Before compiling, print the installed Bicep version.
- Very specific: line 97
Run all validation required by sync-aio-bicep-templates, then run the repository CI-equivalent tests relevant to every changed file.
- Distinctive: line 117
Stop at the review gate. Do not merge and do not trigger integration tests before GitHub reports that this exact PR was merged into the …
- Distinctive: line 128
Update the local base branch without overwriting local work.
- Distinctive: line 140
If tests fail or are cancelled, print the failing job URLs and stop.
- Distinctive: line 141
When all jobs succeed, summarize scenarios and conclusions, then ask for confirmation before phase 3.
- Distinctive: line 164
Stop at the approval gate.
- Distinctive: line 166
After approval, watch the same run to completion.
- Distinctive: line 168
Do not run the public extension-index hand-off.
- Distinctive: line 173
Never continue from a failed PR check, integration-test run, security check, build, linter, approval rejection, or upload.
- Very specific: line 175
Never use continue-on-error=true for an alpha publication candidate.
- Very specific: line 178
Do not delete test resources automatically after a failure when keep-on-failure was requested.
- Distinctive: line 191
every manual handoff message printed at the review and approval gates.
≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
On-demand alpha build
Use this workflow for an alpha build requested from a development or release ref. This skill orchestrates the release;
it does not duplicate template-generation rules from sync-aio-bicep-templates.
This workflow is resumable across human review and approval. Do not wait or poll indefinitely. At each human gate, record the PR or workflow URL, report the exact resume condition, and stop. On the next invocation, inspect the supplied URL or run ID and continue from the first incomplete phase.
Required inputs
Ask for these at the start. Do not infer or invent them:
- local path to the
azure-iot-operations-testsrepository (default may be~/work/azure-iot-operations-testsonly when that path exists); - exact tests-repository branch, tag, or commit to build from;
- any tests-repository PRs or commits whose changes are required in the build, or explicit confirmation that there are none. For an active PR, collect its source branch and exact source commit as well as its PR URL;
- release moniker expected in
Deployment/release.json; - desired PEP 440 alpha CLI version, such as
2.10.0a1; - CLI PR base branch; ask the requester to choose explicitly (typically
devorpreview) and do not assume a default; - integration-test scenarios for
.github/workflows/int_test.yml(default: all scenarios); the workflow must be dispatched against the CLI PR base branch after the preparation PR is merged; - integration-test resource group and optional runtime arguments, or confirmation to use workflow defaults;
Optional resume inputs:
- PR URL or number;
- integration-test workflow run URL or ID;
- release workflow run URL or ID.
Safety boundaries
- Never commit, push, create a PR, trigger a workflow, approve an environment, or publish merely because preflight succeeded. Show the proposed action and obtain explicit confirmation immediately before each remote write.
- Never merge the generated PR. A human reviewer owns approval and merge.
- Never bypass the
productionenvironment approval inrelease_workflow.yml. - At each human gate, print a ready-to-send status message containing the relevant GitHub URLs so the requester can share it through their available communication channel. Do not store internal channel URLs or individual approval contacts in this public repository. Resolve approvers from the protected GitHub environment or user input at runtime.
- Never create a GitHub release for an alpha build. Alpha versions are not public GitHub releases and do not enter the public Azure CLI extension index.
- Preserve unrelated local changes. Stop if any file that the template-sync workflow may edit is already modified.
- Treat the requested tests-repository ref as immutable input. Export it; do not switch or edit that source worktree.
Phase 1: preflight and prepare the PR
- Confirm the current repository is
azure-iot-ops-cli-extension, the GitHub remote targets the expected repository,gh auth statussucceeds, and the CLI PR base branch exists on the remote. - Run the full preflight from
sync-aio-bicep-templatesfor the supplied tests-repository ref and release moniker, including its local-versus-remote commit comparison and dirty-file protection. Resolve every required tests-repository PR or commit before compiling:
- resolve the selected tests ref to an immutable commit;
- resolve each required commit and verify it is an ancestor of the selected commit with
git merge-base --is-ancestor <required-commit> <selected-commit>; - for a required PR, query its current status and source commit. An active or unmerged PR is not included merely because it targets the selected branch;
- if a required PR is active and its commit is not an ancestor, stop and ask whether to build from that PR's exact source commit/ref or wait for it to merge. Never silently combine commits, create a merge commit, or continue from the target branch;
- list the files changed by every required commit and report whether each belongs to the compiled transitive closure. If it is outside that closure, stop and explain that template generation cannot include its effect;
- after compilation and approved redactions, compare the affected generated paths and confirm that each required change survives. A release-policy exclusion must name only the paths being removed; do not treat approval to exclude one feature, such as GDS Manager, as approval to remove an independent OPC UA condition.
Include this source-inclusion evidence in the Phase 1 report and PR body. This guard prevents an active service-team PR from being mistaken for content already present on its target release branch.
Before compiling, print the installed Bicep version. The requester explicitly requires upgrading Bicep for alpha preparation, but
az bicep upgradechanges a shared machine tool. Show the current version and ask for explicit confirmation immediately before running:cd <tests-repository>/Deployment az bicep upgrade az bicep versionRecord the old and new versions. Do not run this command during a resumed phase, and do not downgrade. After the upgrade, apply the sync skill's guard that rejects an installed compiler older than the compiler embedded in the current template.
- Invoke the complete
sync-aio-bicep-templatesworkflow using the supplied ref, moniker, and explicit alpha CLI version. Do not implement a shortened constants-only sync: the template, its hash, test expectations, release constants, and connector constant must all come from the same compile. Do not repeat its OPC UA connector query here: the sync workflow already extracts the tag key-agnostically from the unredacted instance compile, treats a missing value as blocking, and reconcilesOPCUA_CONNECTOR_VERSION. Carry its reported tag into this workflow's summary and PR metadata. - Validate the requested CLI version with
packaging.version.Versionand requireis_prereleaseto be true. Compare it withVERSIONhistory on the CLI base branch and open PRs becausegh release listcannot prove an alpha version is unused. Stop on reuse or ambiguity. - Run all validation required by
sync-aio-bicep-templates, then run the repository CI-equivalent tests relevant to every changed file. Do not proceed while any check fails. - Show the complete diff summary, behavioral-change report, required-PR/commit inclusion evidence, source provenance, Bicep versions, selected source ref and commit, alpha version, and connector tag. Ask for confirmation before creating a branch, commit, push, or PR.
- From the latest remote CLI base branch, create a focused branch named
<alias>/alpha-<CLI_VERSION>, commit with a conventional title, push it, and create a PR targeting the chosen base. Include the source ref/commit, release moniker, Bicep compiler version, alpha version, connector tag, behavioral changes, redactions or policy overrides, and validation results in the PR body. Request reviewers only when their exact GitHub handles were supplied. Report the PR URL and print this ready-to-send review request, substituting real values, so the requester can share it through their available communication channel:
Alpha CLI <CLI_VERSION> preparation PR is ready: <PR_URL> Source: azure-iot-operations-tests <SOURCE_REF> @ <SOURCE_COMMIT> Validation: <SUMMARY> Please review and merge into <CLI_BASE_BRANCH>. Reply with the PR URL after merge to continue integration tests.- Stop at the review gate. Do not merge and do not trigger integration tests before GitHub reports that this exact PR was merged into the expected base branch.
Phase 2: after the PR is merged, run integration tests
- Resolve the supplied PR with
gh pr viewand verify all of the following:- state is
MERGED; baseRefNameequals the requested CLI base branch;- the merge commit is reachable from the current remote base branch;
- the merged
VERSIONequals the requested alpha version; - the merged source-derived constants and templates equal those reviewed in phase 1.
- state is
- Update the local base branch without overwriting local work. Use a clean worktree or stop.
- Show the exact dispatch inputs and ask for confirmation before triggering
.github/workflows/int_test.ymlwith--ref <CLI_BASE_BRANCH>. The ref must be the preparation PR's merged base branch, not the PR head branch or merge ref. Omittest-scenariosto run all scenarios; otherwise pass the user-supplied comma-separated list. Pass resource group and runtime inputs only when explicitly supplied. - Immediately record the resulting run URL and database ID. Because workflow dispatch does not reliably return the
run ID, correlate only runs created after the dispatch timestamp, on the exact branch, event
workflow_dispatch, workflow file, and authenticated actor. If zero or multiple runs match, stop and ask instead of selecting the newest run blindly. gh run watch <RUN_ID> --exit-statusmay be used for the finite integration-test run. If the session ends first, report the run URL and resume from it later.- If tests fail or are cancelled, print the failing job URLs and stop. Do not start a release build.
- When all jobs succeed, summarize scenarios and conclusions, then ask for confirmation before phase 3.
Phase 3: build and publish the alpha wheel
- Reconfirm that the integration-test run succeeded against the same merge commit and requested alpha version.
- Show and confirm this release dispatch policy:
- ref: the merged CLI base branch;
continue-on-error=false;github_release=false;upload_wheel=true.
- Trigger
.github/workflows/release_workflow.ymlwith those inputs. Correlate and record its run exactly as in phase 2; never select a run solely because it is newest. - Watch until the run either completes or reaches the
productionenvironment approval gate. Never approve it. At the approval gate, report the workflow URL and print this ready-to-send approval request so the requester can share it through their available communication channel:
Alpha CLI <CLI_VERSION> release workflow is waiting for production approval: <RUN_URL> Integration tests passed: <INT_TEST_RUN_URL> Approval uploads the alpha wheel to the private storage channel; it does not create a GitHub release. Approvers: <APPROVER_HANDLES>- Stop at the approval gate. Resume only after a user supplies the run URL or ID and GitHub reports that approval was granted.
- After approval, watch the same run to completion. Require the upload job to succeed. Report the run and artifact URLs available from GitHub, but do not claim the wheel is usable through an index unless that has been verified.
- Do not run the public extension-index hand-off. Alpha versions are not published as GitHub releases and therefore do not have a public wheel URL for the index.
Failure and cancellation behavior
- Never continue from a failed PR check, integration-test run, security check, build, linter, approval rejection, or upload.
- Never use
continue-on-error=truefor an alpha publication candidate. - On cancellation, report the exact completed phase, immutable source commit, PR URL, merge commit, workflow run IDs, and safe resume command or input.
- Do not delete test resources automatically after a failure when
keep-on-failurewas requested; report the cleanup deadline and the cluster-cleanup workflow instead.
Completion report
A successful run reports:
- tests-repository ref and resolved commit;
- Bicep version before and after the approved upgrade;
- release moniker, AIO version/train, CLI alpha version, and OPC UA connector tag;
- PR URL and merge commit;
- integration-test run URL and scenario conclusions;
- release workflow URL and upload conclusion;
- every manual handoff message printed at the review and approval gates;
- confirmation that no GitHub release or public-index update was performed.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

