원클릭으로
github-release-workflow
Complete GitHub Actions workflow for automated releases with CHANGELOG-based versioning
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Complete GitHub Actions workflow for automated releases with CHANGELOG-based versioning
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Robust two-phase process termination pattern for PyQt6 apps with UI feedback and guaranteed cleanup
Build Python/PyQt6 apps into standalone executables using Nuitka
Non-blocking subprocess execution with real-time output streaming
Complete ClawdBot CLI command reference for all operations
ClawdBot control panel UI requirements and architecture
Code style rules - clean, minimal, comment-first approach
| name | github-release-workflow |
| description | Complete GitHub Actions workflow for automated releases with CHANGELOG-based versioning |
Automated release workflow using GitHub Actions that builds cross-platform binaries and publishes them when a release is published.
This workflow consists of 4 interconnected GitHub Actions workflows:
┌─────────────────────────────────────────────────────────────┐
│ Push to master │
└─────────────────────┬───────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────┐
│ 1. auto-draft-release.yml │
│ • Reads version from CHANGELOG.md │
│ • Extracts release notes │
│ • Creates/updates draft release │
└─────────────────────┬───────────────────────────────────────┘
│
│ (Manual: Publish release on GitHub)
▼
┌─────────────────────────────────────────────────────────────┐
│ 2. publish.yml │
│ • Triggered when release is published │
│ • Extracts version from tag │
│ • Orchestrates parallel builds │
└─────────┬────────────────────────────────┬──────────────────┘
│ │
▼ ▼
┌──────────────────────┐ ┌───────────────────────────┐
│ 3a. build-windows │ │ 3b. build-macos │
│ • PyInstaller exe │ │ • PyInstaller .app │
│ • Uploads artifact │ │ • Uploads artifact │
└──────────┬───────────┘ └───────────┬───────────────┘
│ │
└───────────┬───────────────────┘
▼
┌────────────────────────────────┐
│ 4. upload-assets.yml │
│ • Downloads artifacts │
│ • Uploads to release │
└────────────────────────────────┘
auto-draft-release.yml)Purpose: Automatically create draft releases from CHANGELOG.md
Triggers:
on:
push:
branches:
- master
What it does:
CHANGELOG.md## v1.0.2)v1.0.2v1.0.2Key steps:
- name: Extract latest version from CHANGELOG
run: |
VERSION=$(grep -m 1 "^## " CHANGELOG.md | sed -E 's/^## \[?v?([0-9]+(\.[0-9]+)+).*/\1/')
TAG_NAME="v$VERSION"
echo "version=$VERSION" >> $GITHUB_OUTPUT
echo "tag=$TAG_NAME" >> $GITHUB_OUTPUT
- name: Extract release notes from CHANGELOG
run: |
# Extract content between current version and next version header
CURRENT_VERSION_LINE=$(grep -n "^## .*$VERSION" CHANGELOG.md | head -1 | cut -d: -f1)
NEXT_VERSION_LINE=$(tail -n +$((CURRENT_VERSION_LINE + 1)) CHANGELOG.md | grep -n "^## " | head -1 | cut -d: -f1)
# Extract and save release notes
- name: Create or update draft release
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ steps.version.outputs.tag }}
name: ${{ steps.version.outputs.tag }}
body: ${{ steps.changelog.outputs.notes }}
draft: true
CHANGELOG.md Format:
# Changelog
## v1.0.2
- Fixed gateway stop button UI issues
- Added dynamic port detection
- Improved error handling
## v1.0.1
- Initial release
publish.yml)Purpose: Orchestrate builds when release is published
Triggers:
on:
release:
types: [published]
What it does:
v1.0.2 → 1.0.2)build-windows.yml in parallelbuild-macos.yml in parallelupload-assets.yml after builds completeKey structure:
jobs:
setup:
runs-on: ubuntu-latest
outputs:
version: ${{ steps.get_version.outputs.version }}
tag_name: ${{ steps.get_version.outputs.tag_name }}
steps:
- name: Extract version from release tag
run: |
tag_name="${{ github.event.release.tag_name }}"
version="${tag_name#v}" # Remove 'v' prefix
echo "version=$version" >> $GITHUB_OUTPUT
build-windows:
needs: setup
uses: ./.github/workflows/build-windows.yml # Reusable workflow
with:
version: ${{ needs.setup.outputs.version }}
build-macos:
needs: setup
uses: ./.github/workflows/build-macos.yml
with:
version: ${{ needs.setup.outputs.version }}
upload-assets:
needs: [setup, build-windows, build-macos]
uses: ./.github/workflows/upload-assets.yml
with:
version: ${{ needs.setup.outputs.version }}
tag_name: ${{ needs.setup.outputs.tag_name }}
build-windows.yml)Purpose: Build Windows executable using PyInstaller
Type: Reusable workflow (workflow_call)
Inputs:
version: Version string (e.g., 1.0.2)What it does:
pyinstaller --name "ClawdBot-Control-Panel" \
--onefile --windowed \
--icon="assets/clawdbot.png" \
--add-data="assets;assets" \
main.py
ClawdBot-Control-Panel.exe → ClawdBot-Control-Panel-v1.0.2-Windows.exeKey steps:
- name: Install dependencies
run: |
pip install pyqt6 websockets pyinstaller pillow
- name: Build Windows executable
run: |
pyinstaller --name "ClawdBot-Control-Panel" \
--onefile --windowed \
--icon="assets/clawdbot.png" \
--add-data="assets;assets" \
--noconfirm --clean main.py
- name: Rename executable
run: |
$version = "${{ inputs.version }}"
Move-Item "dist\ClawdBot-Control-Panel.exe" "dist\ClawdBot-Control-Panel-v$version-Windows.exe"
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: windows-exe
path: dist/*.exe
retention-days: 1
build-macos.yml)Purpose: Build macOS application using PyInstaller
Type: Reusable workflow (workflow_call)
Inputs:
version: Version string (e.g., 1.0.2)What it does:
pyinstaller --name "ClawdBot-Control-Panel" \
--windowed \
--icon="assets/clawdbot.png" \
--add-data="assets:assets" \
main.py
Note: --add-data uses : on macOS/Linux, ; on WindowsClawdBot-Control-Panel-v1.0.2-macOS.zipKey steps:
- name: Install dependencies
run: |
pip install pyqt6 websockets pyinstaller pillow
- name: Build macOS app
run: |
pyinstaller --name "ClawdBot-Control-Panel" \
--windowed \
--icon="assets/clawdbot.png" \
--add-data="assets:assets" \
--noconfirm --clean main.py
- name: Create macOS zip
run: |
version="${{ inputs.version }}"
cd dist
zip -r "ClawdBot-Control-Panel-v$version-macOS.zip" "ClawdBot-Control-Panel.app"
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: macos-app
path: dist/*.zip
upload-assets.yml)Purpose: Download artifacts and upload to release
Type: Reusable workflow (workflow_call)
Inputs:
version: Version stringtag_name: Full tag (e.g., v1.0.2)What it does:
build-windows)build-macos)Key steps:
- name: Download Windows artifact
uses: actions/download-artifact@v4
with:
name: windows-exe
path: dist/
- name: Download macOS artifact
uses: actions/download-artifact@v4
with:
name: macos-app
path: dist/
- name: Upload assets to release
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ inputs.tag_name }}
files: |
dist/*.exe
dist/*.zip
fail_on_unmatched_files: true
# Changelog
## v1.0.3
- New feature
- Bug fix
- Improvement
## v1.0.2
- Previous changes
git add CHANGELOG.md
git commit -m "chore: release v1.0.3"
git push origin master
Result: Draft release v1.0.3 is automatically created on GitHub
v1.0.3Click "Publish release" button
Result:
publish.yml triggersClawdBot-Control-Panel-v1.0.3-Windows.exeClawdBot-Control-Panel-v1.0.3-macOS.zip.github/workflows/
├── auto-draft-release.yml # Auto-create drafts from CHANGELOG
├── publish.yml # Main orchestration
├── build-windows.yml # Windows build (reusable)
├── build-macos.yml # macOS build (reusable)
└── upload-assets.yml # Upload artifacts (reusable)
CHANGELOG.md # Source of truth for versions
Use workflow_call for modular, reusable workflows:
# In publish.yml
build-windows:
uses: ./.github/workflows/build-windows.yml
with:
version: ${{ needs.setup.outputs.version }}
# In build-windows.yml
on:
workflow_call:
inputs:
version:
required: true
type: string
Windows and macOS builds run in parallel for speed:
build-windows:
needs: setup
uses: ./.github/workflows/build-windows.yml
build-macos:
needs: setup
uses: ./.github/workflows/build-macos.yml
upload-assets:
needs: [setup, build-windows, build-macos] # Wait for both
Build artifacts are uploaded then downloaded:
# In build-windows.yml
- uses: actions/upload-artifact@v4
with:
name: windows-exe
path: dist/*.exe
retention-days: 1 # Auto-delete after 1 day
# In upload-assets.yml
- uses: actions/download-artifact@v4
with:
name: windows-exe
path: dist/
Single source of truth in CHANGELOG.md:
Required in workflow files:
permissions:
contents: write # Needed to create releases and upload assets
Required in both build workflows:
pip install pyqt6 websockets pyinstaller pillow
Why Pillow? PyInstaller needs it to convert PNG icons to platform-specific formats (ICNS on macOS, ICO on Windows).
## v1.0.0 formatmaster branchadd-data uses : separator*.exe, *.zip)retention-days hasn't expired✅ Automated: Push to master → Draft created automatically
✅ Consistent: CHANGELOG is single source of truth
✅ Fast: Parallel builds (Windows + macOS)
✅ Modular: Reusable workflows for each platform
✅ Clean: Artifacts auto-deleted after 1 day
✅ Reliable: Built and uploaded in one workflow run
Developer updates CHANGELOG.md:
## v1.0.4
- Added feature X
Developer pushes to master:
git push origin master
GitHub Actions:
v1.0.4 createdMaintainer publishes release on GitHub
GitHub Actions:
Users download:
ClawdBot-Control-Panel-v1.0.4-Windows.exeClawdBot-Control-Panel-v1.0.4-macOS.zip