Skip to content

Commit 18bbf0c

Browse files
authored
Merge pull request #3 from oposs/feat/dispatch-release-template
skill: ship release/validate workflows as artifacts (dispatch-default) + bump actions
2 parents edf84b5 + 2c9c615 commit 18bbf0c

6 files changed

Lines changed: 455 additions & 47 deletions

File tree

CHANGES.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,20 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
88
## [Unreleased]
99

1010
### New
11+
- Ship the release/CI workflows as copyable skill artifacts under
12+
`skills/checkmk-plugin/assets/` (`release.yml`, `validate.yml`,
13+
`CHANGES.md.template`) so plugin repos bootstrap CI with a `cp`, and the skill
14+
docs stay light instead of inlining ~250 lines of YAML.
1115

1216
### Changed
17+
- Document the `workflow_dispatch` + `CHANGES.md` release pipeline as the
18+
recommended default in the checkmk-plugin skill (SKILL.md and
19+
`references/mkp-builder.md`); keep the minimal tag-push workflow as a short
20+
alternative. Reference the bundled artifacts instead of inlining them.
21+
- Bump GitHub Actions in the shipped templates to current majors:
22+
`actions/checkout` v4→v7, `actions/upload-artifact` v4→v7,
23+
`actions/download-artifact` v4→v8, `softprops/action-gh-release` v2→v3
24+
(`oposs/mkp-builder` stays `@v2`).
1325

1426
### Fixed
1527

skills/checkmk-plugin/SKILL.md

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ your-plugin-repo/
6262
| +-- agents/plugins/ # Agent scripts (bash/python, executable)
6363
| \-- notifications/ # Notification scripts (executable)
6464
+-- .mkp-builder.ini # MKP packaging config
65-
\-- .github/workflows/build.yml # CI/CD
65+
\-- .github/workflows/release.yml # CI/CD
6666
```
6767

6868
**Required symlink** (prevents production path issues):
@@ -301,31 +301,31 @@ validate_python = true
301301
```
302302

303303
### GitHub Actions workflow
304-
```yaml
305-
name: Build MKP
306-
on:
307-
push:
308-
tags: ['v*']
309-
jobs:
310-
build:
311-
runs-on: ubuntu-latest
312-
steps:
313-
- uses: actions/checkout@v4
314-
- name: Extract version
315-
id: version
316-
run: echo "version=${GITHUB_REF#refs/tags/v}" >> $GITHUB_OUTPUT
317-
- name: Build MKP
318-
id: build
319-
uses: oposs/mkp-builder@v2
320-
with:
321-
version: ${{ steps.version.outputs.version }}
322-
- name: Create Release
323-
uses: softprops/action-gh-release@v2
324-
with:
325-
files: ${{ steps.build.outputs.package-file }}
304+
305+
Ship the ready-made release pipeline instead of hand-writing YAML — copy the bundled
306+
artifacts into the plugin repo:
307+
308+
```bash
309+
cp <skill-dir>/assets/release.yml .github/workflows/release.yml
310+
cp <skill-dir>/assets/CHANGES.md.template CHANGES.md # only if the repo has no CHANGES.md yet
311+
cp <skill-dir>/assets/validate.yml .github/workflows/validate.yml # optional: build-check PRs
326312
```
327313

328-
Read `references/mkp-builder.md` for the full MKP builder reference including advanced workflows, outputs, troubleshooting, and MKP format details.
314+
`assets/release.yml` is the recommended **manual `workflow_dispatch`** release: you pick
315+
`bugfix`/`feature`/`major` in the Actions UI, it auto-computes the next semver from the
316+
latest tag, rolls the `CHANGES.md` `## [Unreleased]` section into a dated version section,
317+
tags, builds the MKP via `oposs/mkp-builder@v2`, and publishes a GitHub Release whose body
318+
is that changelog section. It is repo-agnostic — it reads the package name/versions from
319+
`.mkp-builder.ini` and the notes from `CHANGES.md`, so no per-repo edits are needed.
320+
321+
Keep a `CHANGES.md` (see the template) and add entries under `## [Unreleased]` as you work.
322+
323+
Working on an **existing** plugin that already has a release workflow? You don't need to
324+
touch any of this — the artifacts are only for bootstrapping a repo's CI.
325+
326+
Read `references/mkp-builder.md` for the full MKP builder reference (the dispatch workflow
327+
walkthrough, the minimal tag-push alternative, action inputs/outputs, troubleshooting, and
328+
MKP format details).
329329

330330
## Upgrading Existing Plugins
331331

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Changelog
2+
3+
All notable changes to this project will be documented in this file.
4+
5+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7+
8+
## [Unreleased]
9+
10+
### New
11+
12+
- Initial release.
13+
14+
### Changed
15+
16+
### Fixed

0 commit comments

Comments
 (0)