CLI-1871: Add sync-skills GitHub Actions workflow. - #2044
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #2044 +/- ##
=========================================
Coverage 92.76% 92.76%
Complexity 2032 2032
=========================================
Files 126 126
Lines 7338 7338
=========================================
Hits 6807 6807
Misses 531 531 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
Try the dev build for this PR: https://acquia-cli.s3.amazonaws.com/build/pr/2044/acli.phar |
There was a problem hiding this comment.
🟡 Changes recommended
The new workflow is likely to fail in common cases (missing PHP runtime, writing to /usr/local/bin, and manual dispatch tag resolution) and includes an unused command JSON generation step that needs clarification or integration.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
This PR adds a new GitHub Actions workflow (sync-skills.yml) intended to automate syncing Acquia CLI (ACLI) “skills” metadata to the separate acquia-skills repository when a release is published or when manually triggered.
Changes:
- Introduces a
release+workflow_dispatchtriggered workflow to resolve an ACLI version, read the Acquia spec version, and download an ACLI release PHAR. - Generates a commands JSON file via
acli list --format=json. - Dispatches a
repository_dispatchevent toacquia/acquia-skillswith version/spec/force payload fields.
File summaries
| File | Description |
|---|---|
.github/workflows/sync-skills.yml |
Adds an automation workflow to orchestrate version resolution, binary download, and cross-repo dispatch for syncing skills. |
Review details
Suppressed comments (1)
.github/workflows/sync-skills.yml:29
- On manual runs, resolving the tag via
github.ref_namecan point at a branch name. Consider honoring the newtaginput and otherwise resolving the latest release tag so the download step consistently targets a real release asset.
- name: Resolve version tag
id: version
run: |
if [ "${{ github.event_name }}" = "release" ]; then
echo "tag=${{ github.event.release.tag_name }}" >> $GITHUB_OUTPUT
else
echo "tag=${{ github.ref_name }}" >> $GITHUB_OUTPUT
fi
- Files reviewed: 1/1 changed files
- Comments generated: 4
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
This pull request introduces a new GitHub Actions workflow,
sync-skills.yml, to automate syncing ACLI skills with theacquia-skillsrepository. The workflow is triggered on releases and manual dispatch, and it handles version resolution, downloads the ACLI binary, generates command data, and dispatches a sync event to the target repository.Workflow automation:
.github/workflows/sync-skills.ymlto automate syncing ACLI skills to theacquia-skillsrepository on release or manual trigger, including options for forced syncs.