Skip to content

Build & Release Package #32

Build & Release Package

Build & Release Package #32

Workflow file for this run

# @format
on:
push:
tags:
- '*'
name: Build & Release Package
jobs:
build-spk:
name: Build Package
runs-on: ubuntu-latest
strategy:
fail-fast: false
max-parallel: 1
matrix:
dsm: ['7.0']
arch: ['avoton']
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Build Package
uses: tomgrv/synology-package-builder@v1
with:
dsm: ${{ matrix.dsm }}
arch: ${{ matrix.arch }}
output: ./dist
- name: Upload Package
uses: actions/upload-artifact@v4
with:
name: packages-${{ matrix.dsm }}-${{ matrix.arch }}
path: ./dist/*.spk
create-release:
name: Create Release
runs-on: ubuntu-latest
needs: build-spk
if: startsWith(github.ref, 'refs/tags/')
permissions:
contents: write
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Download Package Artifact
uses: actions/download-artifact@v4
with:
path: ./dist
- uses: rickstaa/action-contains-tag@v1
id: is_on_main
with:
reference: 'main'
tag: '${{ github.ref }}'
- name: Create Release
id: create_release
uses: softprops/action-gh-release@v2
with:
files: ./dist/**/*.spk
draft: ${{ steps.is_on_main.outputs.retval != 'true' }}
prerelease: ${{ contains(github.ref, '-') }}
fail_on_unmatched_files: true
generate_release_notes: true
body_path: CHANGELOG.md