Skip to content

Commit 699d3ee

Browse files
jamesarichclaude
andcommitted
ci: auto-trigger KMP publish on release; fix broken CI badge
The KMP artifact's tag->publish automation never fired. create_tag.yml creates the release/tag with the default GITHUB_TOKEN, and GitHub deliberately suppresses `push: tags` triggers for refs created by GITHUB_TOKEN — so publish-kmp.yml only ever ran via manual workflow_dispatch (v2.7.26 was published by hand). Fix without adding a secret: create_tag.yml now explicitly dispatches publish-kmp.yml after creating the release (workflow_dispatch is exempt from the GITHUB_TOKEN trigger suppression), passing the new version. Adds `actions: write` so `gh workflow run` can dispatch it. The existing `push: tags` trigger on publish-kmp.yml is kept as a fallback for tags pushed with a user/PAT credential. Also fix the root README CI badge, which pointed at a nonexistent ci.yml, to the actual pull_request.yml workflow. Part of the Meshtastic KMP library standard alignment (P0: release reliability + docs accuracy). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1 parent b73e5ad commit 699d3ee

2 files changed

Lines changed: 10 additions & 1 deletion

File tree

.github/workflows/create_tag.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ name: Create tag
22

33
permissions:
44
contents: write
5+
actions: write
56

67
on:
78
workflow_dispatch:
@@ -57,6 +58,14 @@ jobs:
5758
generateReleaseNotes: true
5859
token: ${{ github.token }}
5960

61+
# Tags created via GITHUB_TOKEN do not fire `push: tags` triggers, so
62+
# publish-kmp.yml never ran automatically. Dispatch it explicitly
63+
# (workflow_dispatch is exempt from the GITHUB_TOKEN trigger suppression).
64+
- name: Trigger KMP publish workflow
65+
env:
66+
GH_TOKEN: ${{ github.token }}
67+
run: gh workflow run publish-kmp.yml -f version=${{ steps.version.outputs.NEW_VERSION }}
68+
6069
- name: Setup Buf
6170
uses: bufbuild/buf-action@v1.4.0
6271
with:

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Meshtastic Protobuf Definitions
22

3-
[![CI](https://img.shields.io/github/actions/workflow/status/meshtastic/protobufs/ci.yml?branch=master&label=actions&logo=github&color=yellow)](https://github.com/meshtastic/protobufs/actions/workflows/ci.yml)
3+
[![CI](https://img.shields.io/github/actions/workflow/status/meshtastic/protobufs/pull_request.yml?branch=master&label=actions&logo=github&color=yellow)](https://github.com/meshtastic/protobufs/actions/workflows/pull_request.yml)
44
[![CLA assistant](https://cla-assistant.io/readme/badge/meshtastic/protobufs)](https://cla-assistant.io/meshtastic/protobufs)
55
[![Fiscal Contributors](https://opencollective.com/meshtastic/tiers/badge.svg?label=Fiscal%20Contributors&color=deeppink)](https://opencollective.com/meshtastic/)
66
[![Vercel](https://img.shields.io/static/v1?label=Powered%20by&message=Vercel&style=flat&logo=vercel&color=000000)](https://vercel.com?utm_source=meshtastic&utm_campaign=oss)

0 commit comments

Comments
 (0)