mirror of
https://github.com/zephrynis/ptero-sidebar.git
synced 2026-04-17 09:31:55 +00:00
Create export_ext.yml
This commit is contained in:
35
.github/workflows/export_ext.yml
vendored
Normal file
35
.github/workflows/export_ext.yml
vendored
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
name: Create Release
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
release:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout code
|
||||||
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: Extract version from conf.yml
|
||||||
|
id: get_version
|
||||||
|
run: |
|
||||||
|
VERSION=$(sed -n 's/^[[:space:]]*version:[[:space:]]*//p' conf.yml | head -n 1)
|
||||||
|
echo "Detected version: $VERSION"
|
||||||
|
echo "VERSION=$VERSION" >> $GITHUB_ENV
|
||||||
|
echo "::set-output name=VERSION::$VERSION"
|
||||||
|
|
||||||
|
- name: Create zip of project files
|
||||||
|
run: |
|
||||||
|
zip -r sidebar-${{ env.VERSION }}.blueprint . -x "*.git*"
|
||||||
|
|
||||||
|
- name: Create GitHub Release and Upload Asset
|
||||||
|
uses: ncipollo/release-action@v1
|
||||||
|
with:
|
||||||
|
tag: "v${{ env.VERSION }}"
|
||||||
|
release_name: "Release v${{ env.VERSION }}"
|
||||||
|
body: "Automated release based on version ${{ env.VERSION }}"
|
||||||
|
draft: false
|
||||||
|
prerelease: false
|
||||||
|
assets: sidebar-${{ env.VERSION }}.blueprint
|
||||||
Reference in New Issue
Block a user