Skip to content

Try tag detection before release. #10

Try tag detection before release.

Try tag detection before release. #10

Workflow file for this run

name: package
on:
push:
paths:
- '.github/workflows/package.yml'
- 'custom-prompt/**'
workflow_dispatch:
jobs:
build:
name: build on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-13, macos-14, ubuntu-22.04, windows-2022]
defaults:
run:
working-directory: custom-prompt
steps:
- uses: actions/checkout@v4
- if: runner.os == 'Linux'
run: sudo apt install libnotify-dev
- run: make -j release CC=gcc
- if: runner.os == 'Linux'
run: tar czf custom-prompt-amd64-linux.tgz *-prompt
- if: matrix.os == 'macos-13'
run: tar czf custom-prompt-amd64-darwin.tgz *-prompt
- if: matrix.os == 'macos-14'
run: tar czf custom-prompt-aarch64-darwin.tgz *-prompt
- if: runner.os == 'Windows'
run: |
7z a -ttar custom-prompt-amd64-windows.tar *-prompt.exe
7z a -tgzip custom-prompt-amd64-windows.tgz *.tar
- uses: actions/upload-artifact@v4
with:
name: ${{ matrix.os }}
path: 'custom-prompt/*.tgz'
release:
needs: build
runs-on: ubuntu-22.04
env:
GH_TOKEN: ${{ github.token }}
permissions: write-all
steps:
- uses: actions/download-artifact@v4
- if: github.ref_type == 'tag'
run: |
gh release create ${{ github.ref_name }} -t test
gh release upload ${{ github.ref_name }} */*.tgz