Post release version increase and much more #64
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
name: GitHub-actions CI build-runner | |
env: | |
sfos_target: 4.1.0.24 | |
on: | |
push: | |
tags: | |
- '*' | |
pull_request: | |
branches: | |
- master | |
jobs: | |
build: | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Prepare | |
run: mkdir RPMS | |
- name: Build armv7hl | |
uses: coderus/github-sfos-build@master | |
with: | |
release: ${{ env.sfos_target }} | |
arch: armv7hl | |
- name: Build i486 | |
uses: coderus/github-sfos-build@master | |
with: | |
release: ${{ env.sfos_target }} | |
arch: i486 | |
- name: Build aarch64 | |
uses: coderus/github-sfos-build@master | |
with: | |
release: ${{ env.sfos_target }} | |
arch: aarch64 | |
- name: Upload build result | |
uses: actions/upload-artifact@v2 | |
with: | |
name: rpm-build-result | |
path: RPMS | |
- name: Create release | |
if: contains(github.ref, 'release') | |
run: | | |
set -x | |
assets=() | |
for asset in RPMS/*.rpm; do | |
assets+=("-a" "$asset") | |
done | |
tag_name="${GITHUB_REF##*/}" | |
hub release create "${assets[@]}" -m "$tag_name" "$tag_name" | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |