From e839c01a1e2362cd7694fe222eddc66d2295b82b Mon Sep 17 00:00:00 2001 From: Stefan Koelle Date: Tue, 11 Aug 2026 20:02:42 +0200 Subject: [PATCH] fix create release --- .opencode/command/create-release.md | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/.opencode/command/create-release.md b/.opencode/command/create-release.md index 21d59a1..63a4cdb 100644 --- a/.opencode/command/create-release.md +++ b/.opencode/command/create-release.md @@ -14,22 +14,27 @@ Create a release tag and push it to origin. The GitHub Action will automatically - Run `git status --porcelain` - If any output, warn the user and stop (commit first) -3. Analyze changes since last release: - - Run `git log --oneline $(git describe --tags --abbrev=0 HEAD)..HEAD` to list all commits +3. Find the previous tag dynamically: + - Run `git describe --tags --abbrev=0 HEAD` to find the most recent tag before HEAD + - If no previous tag exists (first release), note this and skip to step 5 + - Report the previous tag to the user (e.g. "Previous tag found: v0.9.5") + +4. Analyze changes since the previous tag: + - Run `git log --oneline ..HEAD` to list all commits between the previous tag and HEAD - Read the changed files to understand context - Write a concise, well-structured release summary in English with: - A one-line overview - Bullet points for each notable change (features, fixes, breaking changes) - Keep it developer-friendly, no fluff -4. Create release commit with the summary as message: +5. Create release commit with the summary as message: - Run `git commit --allow-empty -m "release v$ARGUMENTS\n\n"` - The commit message IS the release notes — the GitHub Action picks it up automatically -5. Create annotated tag on that commit: +6. Create annotated tag on that commit: - Run `git tag -a v$ARGUMENTS -m "Release v$ARGUMENTS"` -6. Push commit and tag: +7. Push commit and tag: - Run `git push origin main --tags` (or current branch) -7. Confirm success with the version number +8. Confirm success with the version number