universal-android-debloater.../.github/workflows/release.yml

53 lines
1.4 KiB
YAML

name: Build and release
on:
push:
branches:
- main
paths:
- Cargo.lock
- Cargo.toml
- resources/assets/*.ttf
- src/**
tags-ignore:
- dev-build
env:
dev_tag: dev-build
jobs:
build:
uses: ./.github/workflows/build_artifacts.yml
release:
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')
runs-on: ubuntu-latest
needs: build
permissions:
contents: write
steps:
- uses: actions/checkout@v4
- name: Downloads artifacts
uses: actions/download-artifact@v3
with:
path: bin
- name: Create pre-release
uses: softprops/action-gh-release@v1
with:
body_path: ${{ github.workspace }}/CHANGELOG.md
files: bin/*/uad-ng-*
prerelease: true
# - name: Update dev-build tag
# if: ${{ github.event_name == 'push' }}
# run: |
# git tag -d ${{ env.dev_tag }} || true
# git push origin :refs/tags/${{ env.dev_tag }} || true
# git tag ${{ env.dev_tag }}
# git push origin ${{ env.dev_tag }}
# - name: Create dev-build release
# if: ${{ github.event_name == 'push' }}
# uses: softprops/action-gh-release@v1
# with:
# generate_release_notes: true
# files: bin/*/uad-ng-*
# prerelease: true
# tag_name: ${{ env.dev_tag }}