From fd54e49685673d3af3ea2774b79afdf0c76e000b Mon Sep 17 00:00:00 2001 From: Simona Milanovic Date: Mon, 3 Aug 2026 12:44:19 +0200 Subject: [PATCH 1/5] Update workflows with agent marketplace generation files --- .github/workflows/create-release.yml | 34 ++++++++++++++++++++++++++-- .github/workflows/update-skills.yml | 13 ++++++++++- 2 files changed, 44 insertions(+), 3 deletions(-) diff --git a/.github/workflows/create-release.yml b/.github/workflows/create-release.yml index 92c9029..2598cd6 100644 --- a/.github/workflows/create-release.yml +++ b/.github/workflows/create-release.yml @@ -19,6 +19,33 @@ jobs: uses: actions/checkout@v4 with: ref: main + token: ${{ secrets.ADR_GITHUB_BOT_PAT || secrets.GITHUB_TOKEN }} + + - name: Update Codex Plugin Version + run: | + RAW_TAG="${{ inputs.tag_name }}" + # Strip leading 'v' if present (e.g., v1.0.7 -> 1.0.7) + VERSION="${RAW_TAG#v}" + echo "Updating .codex-plugin/plugin.json version to $VERSION" + + python3 -c " + import json + path = '.codex-plugin/plugin.json' + with open(path, 'r') as f: + data = json.load(f) + data['version'] = '$VERSION' + with open(path, 'w') as f: + json.dump(data, f, indent=2) + f.write('\n') + " + + - name: Commit and push updated version + run: | + git config user.name "android-devrel-github-bot" + git config user.email "android-devrel-github-bot@users.noreply.github.com" + git add .codex-plugin/plugin.json + git commit -m "Bump plugin version to ${{ inputs.tag_name }}" || echo "No version change to commit" + git push origin main - name: Create Zip Archive run: | @@ -26,6 +53,9 @@ jobs: - name: Create Release env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GITHUB_TOKEN: ${{ secrets.ADR_GITHUB_BOT_PAT || secrets.GITHUB_TOKEN }} run: | - gh release create ${{ inputs.tag_name }} android-skills.zip --title "Release ${{ inputs.tag_name }}" --notes "Manual release of main branch contents." + gh release create ${{ inputs.tag_name }} android-skills.zip \ + --target main \ + --title "Release ${{ inputs.tag_name }}" \ + --notes "Release ${{ inputs.tag_name }} of Android Skills." diff --git a/.github/workflows/update-skills.yml b/.github/workflows/update-skills.yml index 08bf523..5c208ef 100644 --- a/.github/workflows/update-skills.yml +++ b/.github/workflows/update-skills.yml @@ -29,10 +29,21 @@ jobs: curl -L -O https://dl.google.com/dac/dac_skills.zip mkdir temp_extract unzip -o dac_skills.zip -d temp_extract - # Only copy directories from the root of the zip, ignoring files in the root + + # 1. Copy non-hidden skill category directories if ls -d temp_extract/[!.]*/ >/dev/null 2>&1; then cp -r temp_extract/[!.]*/ . fi + + # 2. Copy the agent marketplace & plugin directories (.agents, .claude-plugin, .codex-plugin) + for dir in .agents .claude-plugin .codex-plugin; do + if [ -d "temp_extract/$dir" ]; then + rm -rf "$dir" + cp -r "temp_extract/$dir" . + echo "Copied $dir directory." + fi + done + rm -rf temp_extract dac_skills.zip - name: Copy contents of github-skills branch From d5c813eb8d7c15b7ca5c817817af3a3ed087fad5 Mon Sep 17 00:00:00 2001 From: Simona Milanovic Date: Mon, 3 Aug 2026 13:09:33 +0200 Subject: [PATCH 2/5] Fix failing zizmor errors --- .github/workflows/create-release.yml | 26 ++++++++++++++++---------- .github/workflows/update-skills.yml | 2 +- 2 files changed, 17 insertions(+), 11 deletions(-) diff --git a/.github/workflows/create-release.yml b/.github/workflows/create-release.yml index 2598cd6..0a0c28d 100644 --- a/.github/workflows/create-release.yml +++ b/.github/workflows/create-release.yml @@ -16,35 +16,40 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout main - uses: actions/checkout@v4 + uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 with: ref: main token: ${{ secrets.ADR_GITHUB_BOT_PAT || secrets.GITHUB_TOKEN }} - name: Update Codex Plugin Version + env: + TAG_NAME: ${{ inputs.tag_name }} run: | - RAW_TAG="${{ inputs.tag_name }}" - # Strip leading 'v' if present (e.g., v1.0.7 -> 1.0.7) - VERSION="${RAW_TAG#v}" + VERSION="${TAG_NAME#v}" echo "Updating .codex-plugin/plugin.json version to $VERSION" - python3 -c " + VERSION="$VERSION" python3 -c " import json + import os + + version = os.environ['VERSION'] path = '.codex-plugin/plugin.json' with open(path, 'r') as f: data = json.load(f) - data['version'] = '$VERSION' + data['version'] = version with open(path, 'w') as f: json.dump(data, f, indent=2) f.write('\n') " - name: Commit and push updated version + env: + TAG_NAME: ${{ inputs.tag_name }} run: | git config user.name "android-devrel-github-bot" git config user.email "android-devrel-github-bot@users.noreply.github.com" git add .codex-plugin/plugin.json - git commit -m "Bump plugin version to ${{ inputs.tag_name }}" || echo "No version change to commit" + git commit -m "Bump plugin version to $TAG_NAME" || echo "No version change to commit" git push origin main - name: Create Zip Archive @@ -54,8 +59,9 @@ jobs: - name: Create Release env: GITHUB_TOKEN: ${{ secrets.ADR_GITHUB_BOT_PAT || secrets.GITHUB_TOKEN }} + TAG_NAME: ${{ inputs.tag_name }} run: | - gh release create ${{ inputs.tag_name }} android-skills.zip \ + gh release create "$TAG_NAME" android-skills.zip \ --target main \ - --title "Release ${{ inputs.tag_name }}" \ - --notes "Release ${{ inputs.tag_name }} of Android Skills." + --title "Release $TAG_NAME" \ + --notes "Release $TAG_NAME of Android Skills." diff --git a/.github/workflows/update-skills.yml b/.github/workflows/update-skills.yml index 5c208ef..92f23d8 100644 --- a/.github/workflows/update-skills.yml +++ b/.github/workflows/update-skills.yml @@ -14,7 +14,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout main - uses: actions/checkout@v4 + uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 with: ref: main token: ${{ secrets.ADR_GITHUB_BOT_PAT }} From 1f575dbef734a6a330cd4c10e7cab931cedd39f9 Mon Sep 17 00:00:00 2001 From: Simona Milanovic Date: Tue, 4 Aug 2026 12:08:17 +0200 Subject: [PATCH 3/5] Modify update-skills steps to update agent marketplace files and skill lists with every new update --- .github/workflows/update-skills.yml | 57 +++++++++++++++++++++++------ 1 file changed, 45 insertions(+), 12 deletions(-) diff --git a/.github/workflows/update-skills.yml b/.github/workflows/update-skills.yml index 92f23d8..cc3f0ef 100644 --- a/.github/workflows/update-skills.yml +++ b/.github/workflows/update-skills.yml @@ -29,21 +29,10 @@ jobs: curl -L -O https://dl.google.com/dac/dac_skills.zip mkdir temp_extract unzip -o dac_skills.zip -d temp_extract - - # 1. Copy non-hidden skill category directories + # Only copy directories from the root of the zip, ignoring files in the root if ls -d temp_extract/[!.]*/ >/dev/null 2>&1; then cp -r temp_extract/[!.]*/ . fi - - # 2. Copy the agent marketplace & plugin directories (.agents, .claude-plugin, .codex-plugin) - for dir in .agents .claude-plugin .codex-plugin; do - if [ -d "temp_extract/$dir" ]; then - rm -rf "$dir" - cp -r "temp_extract/$dir" . - echo "Copied $dir directory." - fi - done - rm -rf temp_extract dac_skills.zip - name: Copy contents of github-skills branch @@ -70,6 +59,50 @@ jobs: rm -rf temp_skills echo "Successfully copied directories from github-skills branch." + - name: Update Skill Lists in Plugin Files + run: | + python3 -c " + import json + import pathlib + + # Discover all skills + skill_paths = [] + for path in pathlib.Path('.').glob('**/SKILL.md'): + if any(p.startswith('.') for p in path.parts[:-1]): + continue + skill_paths.append(f'./{path.parent.as_posix()}') + + for path in pathlib.Path('.').glob('**/skill.md'): + if any(p.startswith('.') for p in path.parts[:-1]): + continue + p_str = f'./{path.parent.as_posix()}' + if p_str not in skill_paths: + skill_paths.append(p_str) + + skill_paths = sorted(list(set(skill_paths))) + + # 1. Update .claude-plugin/marketplace.json in-place + claude_file = pathlib.Path('.claude-plugin/marketplace.json') + if claude_file.exists(): + with open(claude_file, 'r') as f: + data = json.load(f) + if 'plugins' in data and len(data['plugins']) > 0: + data['plugins'][0]['skills'] = skill_paths + with open(claude_file, 'w') as f: + json.dump(data, f, indent=2) + f.write('\n') + + # 2. Update .codex-plugin/plugin.json in-place + codex_file = pathlib.Path('.codex-plugin/plugin.json') + if codex_file.exists(): + with open(codex_file, 'r') as f: + data = json.load(f) + data['skills'] = [{'source': {'path': p}} for p in skill_paths] + with open(codex_file, 'w') as f: + json.dump(data, f, indent=2) + f.write('\n') + " + - name: Commit and push changes run: | git config user.name "android-devrel-github-bot" From 347926d271095b6f1b47e0b7b4fc79993d5a7266 Mon Sep 17 00:00:00 2001 From: Simona Milanovic Date: Tue, 4 Aug 2026 12:25:32 +0200 Subject: [PATCH 4/5] Modify update-skills steps to update agent marketplace files and skill lists with every new update --- .github/workflows/update-skills.yml | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/.github/workflows/update-skills.yml b/.github/workflows/update-skills.yml index cc3f0ef..26a4a74 100644 --- a/.github/workflows/update-skills.yml +++ b/.github/workflows/update-skills.yml @@ -65,20 +65,13 @@ jobs: import json import pathlib - # Discover all skills + # Discover all skills with SKILL.md skill_paths = [] for path in pathlib.Path('.').glob('**/SKILL.md'): if any(p.startswith('.') for p in path.parts[:-1]): continue skill_paths.append(f'./{path.parent.as_posix()}') - for path in pathlib.Path('.').glob('**/skill.md'): - if any(p.startswith('.') for p in path.parts[:-1]): - continue - p_str = f'./{path.parent.as_posix()}' - if p_str not in skill_paths: - skill_paths.append(p_str) - skill_paths = sorted(list(set(skill_paths))) # 1. Update .claude-plugin/marketplace.json in-place From c822cc60251deb1cfac40f0bda9bcc3b413fc62b Mon Sep 17 00:00:00 2001 From: Simona Milanovic Date: Tue, 4 Aug 2026 16:35:44 +0200 Subject: [PATCH 5/5] Resolve comments --- .github/workflows/update-skills.yml | 34 ++++++++++++++++------------- 1 file changed, 19 insertions(+), 15 deletions(-) diff --git a/.github/workflows/update-skills.yml b/.github/workflows/update-skills.yml index 26a4a74..47afa74 100644 --- a/.github/workflows/update-skills.yml +++ b/.github/workflows/update-skills.yml @@ -76,24 +76,28 @@ jobs: # 1. Update .claude-plugin/marketplace.json in-place claude_file = pathlib.Path('.claude-plugin/marketplace.json') - if claude_file.exists(): - with open(claude_file, 'r') as f: - data = json.load(f) - if 'plugins' in data and len(data['plugins']) > 0: - data['plugins'][0]['skills'] = skill_paths - with open(claude_file, 'w') as f: - json.dump(data, f, indent=2) - f.write('\n') + if not claude_file.exists(): + raise FileNotFoundError(f'Required file {claude_file} does not exist. Ensure you are running on the correct branch.') + + with open(claude_file, 'r') as f: + data = json.load(f) + if 'plugins' in data and len(data['plugins']) > 0: + data['plugins'][0]['skills'] = skill_paths + with open(claude_file, 'w') as f: + json.dump(data, f, indent=2) + f.write('\n') # 2. Update .codex-plugin/plugin.json in-place codex_file = pathlib.Path('.codex-plugin/plugin.json') - if codex_file.exists(): - with open(codex_file, 'r') as f: - data = json.load(f) - data['skills'] = [{'source': {'path': p}} for p in skill_paths] - with open(codex_file, 'w') as f: - json.dump(data, f, indent=2) - f.write('\n') + if not codex_file.exists(): + raise FileNotFoundError(f'Required file {codex_file} does not exist. Ensure you are running on the correct branch.') + + with open(codex_file, 'r') as f: + data = json.load(f) + data['skills'] = [{'source': {'path': p}} for p in skill_paths] + with open(codex_file, 'w') as f: + json.dump(data, f, indent=2) + f.write('\n') " - name: Commit and push changes