mirror of
https://github.com/rivi-s/pfQuest-turtle.git
synced 2026-11-18 00:44:37 +00:00
36 lines
1.2 KiB
YAML
36 lines
1.2 KiB
YAML
name: Release pfQuest-turtle on changes
|
|
on:
|
|
workflow_dispatch:
|
|
permissions:
|
|
contents: write
|
|
actions: read
|
|
jobs:
|
|
release:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Extract version from TOC file
|
|
id: get_version
|
|
run: |
|
|
VERSION=$(grep "## Version:" pfQuest-turtle.toc | sed 's/## Version: //')
|
|
echo "version=$VERSION" >> $GITHUB_OUTPUT
|
|
echo "Found version: $VERSION"
|
|
|
|
- name: Create pfQuest-turtle zip
|
|
run: |
|
|
mkdir pfQuest-turtle
|
|
rsync -av --exclude='.git' --exclude='.github' --exclude='*.md' --exclude='LICENSE' --exclude='.gitattributes' --exclude='pfQuest-turtle' . pfQuest-turtle/
|
|
zip -r pfQuest-turtle.zip pfQuest-turtle/
|
|
|
|
- name: Create Versioned Release and Upload Asset
|
|
uses: softprops/action-gh-release@v2
|
|
with:
|
|
tag_name: pfQuest-turtle-v${{ steps.get_version.outputs.version }}
|
|
name: pfQuest-turtle v${{ steps.get_version.outputs.version }}
|
|
files: pfQuest-turtle.zip
|
|
make_latest: true
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|