forked from damicon/zfswatcher
-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add GitHub workflow for prerelease publishing (#20)
- Loading branch information
Showing
1 changed file
with
57 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,71 @@ | ||
name: Makefile CI | ||
name: ZFSWatcher Makefile CI | ||
|
||
on: | ||
push: | ||
branches: [ contrib ] | ||
branches: | ||
- contrib | ||
pull_request: | ||
branches: [ contrib ] | ||
branches: | ||
- contrib | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
runs-on: ubuntu-20.04 | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Checkout source | ||
uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Install pre-reqs | ||
run: sudo apt-get update && sudo apt-get install -y rpm dpkg-dev debhelper | ||
|
||
- name: Build zfswatcher | ||
- name: Clean build environment | ||
run: make clean | ||
|
||
- name: Build ZFSWatcher | ||
run: make | ||
|
||
runs-on: self-hosted | ||
- name: Build Tarball | ||
run: make dist | ||
|
||
- name: Upload Tarball | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: ZFSWatcher Tarball | ||
path: '*.tar.*' | ||
|
||
- name: Build Debian package | ||
run: make deb | ||
|
||
- name: Upload Debian package and changelog | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: ZFSWatcher DEB and Changelog | ||
path: | | ||
*.deb | ||
*.changes | ||
- name: Build RPM packages | ||
run: make rpm | ||
|
||
- name: Upload RPM packages | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: ZFSWatcher RPMs | ||
path: '*.rpm' | ||
|
||
- name: Publish pre-release | ||
uses: marvinpinto/action-automatic-releases@latest | ||
with: | ||
repo_token: "${{ secrets.GITHUB_TOKEN }}" | ||
prerelease: true | ||
draft: true | ||
automatic_release_tag: latest-dev | ||
title: Development Build | ||
files: | | ||
*.rpm | ||
*.deb |