Files
libmali-rockchip/.github/workflows/build_and_release.yml
2025-01-17 09:31:32 +01:00

47 lines
1.2 KiB
YAML

name: Build and Release Debian Package
on:
push:
branches:
- master
workflow_dispatch:
jobs:
build_and_release:
name: Build and Release Debian Package
runs-on: ubuntu-24.04-arm
permissions:
contents: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install -y build-essential devscripts
- name: Build Debian package
run: |
debuild -us -uc -b && cp -a ../*.deb ./
- name: Get version
id: get_version
run: |
echo "version=$(dpkg-parsechangelog --show-field Version)" >> $GITHUB_OUTPUT
- name: Get commit hash
id: get_commit_hash
uses: prompt/actions-commit-hash@v3
- name: Release
uses: softprops/action-gh-release@v1
with:
name: v${{ steps.get_version.outputs.version }}-${{ steps.get_commit_hash.outputs.short }}
tag_name: v${{ steps.get_version.outputs.version }}-${{ steps.get_commit_hash.outputs.short }}
generate_release_notes: true
files: |
./*.deb