Skip to content

Package and Release #10

Package and Release

Package and Release #10

Workflow file for this run

name: Package and Release
on:
workflow_dispatch:
push:
tags:
- 'v*'
jobs:
package-and-release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Get the version
id: get_version
run: |
# Remove 'v' prefix from tag
VERSION=${GITHUB_REF#refs/tags/v}
echo "VERSION=$VERSION" >> $GITHUB_OUTPUT
echo "VERSION_WITH_V=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
- name: Build plugin
run: |
chmod +x build.sh
./build.sh ${{ steps.get_version.outputs.VERSION }}
- name: Create release artifact
run: |
chmod +x release.sh
./release.sh ${{ steps.get_version.outputs.VERSION }}
- name: Create Release
if: success()
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
gh release create ${{ steps.get_version.outputs.VERSION_WITH_V }} \
--title "Release ${{ steps.get_version.outputs.VERSION_WITH_V }}" \
--notes "Release ${{ steps.get_version.outputs.VERSION_WITH_V }}" \
dist/betterportal-theme-embedded-${{ steps.get_version.outputs.VERSION_WITH_V }}.zip
- name: Update SVN with latest code
run: |
./update-svn.sh
- name: Cleanup
if: always()
run: |
./cleanup.sh