Skip to content

Fix spec file path 2 #7

Fix spec file path 2

Fix spec file path 2 #7

Workflow file for this run

on:
push:
branches:
- master
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Set up RPM environment
run: |
sudo apt-get update
sudo apt-get install -y rpm
mkdir -p ~/rpmbuild/SOURCES
- name: Checkout code
uses: actions/checkout@v2
with:
path: ~/rpmbuild/SOURCES
- name: Build RPM package
run: |
rpmbuild -bb ${{ github.workspace }}/*.spec
- name: Find RPM files
id: findrpm
run: |
echo "::set-output name=files::$(find ~/rpmbuild/RPMS/ -type f -name "*.rpm")"
- name: Find SRPM files
id: findsrpm
run: |
echo "::set-output name=files::$(find ~/rpmbuild/SRPMS/ -type f -name "*.src.rpm")"
- name: Create binary release
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ github.event.repository.releases_url }}
asset_path: ${{ steps.findrpm.outputs.files }}
asset_name: ${{ steps.findrpm.outputs.files }}
asset_content_type: application/x-rpm
- name: Create source release
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ github.event.repository.releases_url }}
asset_path: ${{ steps.findsrpm.outputs.files }}
asset_name: ${{ steps.findsrpm.outputs.files }}
asset_content_type: application/x-rpm