Skip to content

.github: Add release action #171

.github: Add release action

.github: Add release action #171

Workflow file for this run

name: Build all
on:
pull_request:
branches:
- main
push:
branches:
- main
tags:
- "*"
jobs:
MacOS:
if: github.event_name != 'schedule' || github.repository == 'juniorrantila/MusicStudio'
runs-on: macos-latest
steps:
- uses: actions/checkout@v3
- name: Fetch tags and unshallow
run: git fetch --unshallow --tags
- uses: actions/cache/restore@v4
id: restore-cached-toolchain
with:
path: Toolchain
key: ${{ runner.os }}-${{ hashFiles('*/*.sh') }}
- name: Bootstrap toolchain
if: steps.restore-cached-toolchain.outputs.cache-hit != 'true'
run: Toolchain/bootstrap.sh
- uses: actions/cache/save@v4
id: save-toolchain
if: steps.restore-cached-toolchain.outputs.cache-hit != 'true'
with:
path: Toolchain
key: ${{ runner.os }}-${{ hashFiles('*/*.sh') }}
- name: Setup
run: eval $(./bootstrap)
- name: Build
run: ninja -C build
- name: Release
if: startsWith(github.ref, 'refs/tags/')
uses: softprops/action-gh-release@v2
with:
files: build/**