codeation runs a release build #18
Workflow file for this run
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: build release | |
run-name: ${{ github.actor }} runs a release build | |
on: | |
push: | |
tags: | |
- 'v*' | |
jobs: | |
create_release: | |
name: Create release | |
runs-on: ubuntu-latest | |
outputs: | |
upload_url: ${{ steps.create_release.outputs.upload_url }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Create Release | |
id: create_release | |
uses: actions/create-release@latest | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: ${{ github.ref }} | |
release_name: Release ${{ github.ref }} | |
draft: false | |
prerelease: false | |
it_build: | |
needs: create_release | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest, ubuntu-20.04, macos-latest] | |
include: | |
- os: ubuntu-latest | |
target: linux | |
- os: ubuntu-20.04 | |
target: ubuntu.20.04 | |
- os: macos-latest | |
target: darwin | |
- os: macos-14 | |
target: darwin.m1 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Print gcc version | |
run: gcc --version | |
- name: Install GTK 3 (apt-get) | |
if: ${{ matrix.target == 'linux' }} | |
run: sudo apt-get update && sudo apt-get install libgtk-3-dev | |
- name: Install GTK 3 (apt-get, ubuntu.20.04) | |
if: ${{ matrix.target == 'ubuntu.20.04' }} | |
run: sudo apt-get update && sudo apt-get install libgtk-3-dev | |
- name: Install GTK 3 (brew) | |
if: ${{ matrix.target == 'darwin' }} | |
run: brew install gtk+3 | |
- name: Install GTK 3 (brew) | |
if: ${{ matrix.target == 'darwin.m1' }} | |
run: brew install gtk+3 | |
- name: Make all | |
run: make | |
- name: Archive it-${{ matrix.target }}.zip | |
run: zip it-${{ matrix.target }}.zip it | |
- name: Upload Release Asset | |
id: upload-release-asset | |
uses: actions/upload-release-asset@latest | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
upload_url: ${{ needs.create_release.outputs.upload_url }} | |
asset_path: it-${{ matrix.target }}.zip | |
asset_name: it-${{ matrix.target }}.zip | |
asset_content_type: application/zip |