Trigger workflow on release
Build & Attach Release / Build and Attach ZIP (release) Successful in 8s
Build & Attach Release / Build and Attach ZIP (release) Successful in 8s
This commit is contained in:
@@ -1,13 +1,12 @@
|
|||||||
name: Build & Release
|
name: Build & Attach Release
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
release:
|
||||||
tags:
|
types: [published]
|
||||||
- '*'
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-and-release:
|
build-and-release:
|
||||||
name: Build and Create Release
|
name: Build and Attach ZIP
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
@@ -27,15 +26,14 @@ jobs:
|
|||||||
|
|
||||||
- name: Create ZIP archive
|
- name: Create ZIP archive
|
||||||
run: |
|
run: |
|
||||||
# Zipping from inside the dist folder ensures 'dist' isn't the root folder in the zip
|
|
||||||
cd dist
|
cd dist
|
||||||
zip -r ../lirkab-site.zip .
|
zip -r ../lirkab-site.zip .
|
||||||
|
|
||||||
- name: Create Release & Attach ZIP
|
- name: Attach ZIP to Release
|
||||||
uses: softprops/action-gh-release@v2
|
uses: softprops/action-gh-release@v2
|
||||||
with:
|
with:
|
||||||
name: "Release ${{ github.ref_name }}"
|
name: ${{ github.event.release.tag_name }}
|
||||||
body: "Automated release of the Lirkab static site."
|
body: ${{ github.event.release.body || 'Automated release of the Lirkab static site.' }}
|
||||||
files: lirkab-site.zip
|
files: lirkab-site.zip
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
Reference in New Issue
Block a user