Skip to content

Add workflow.

Add workflow. #1

Workflow file for this run

name: Build and Release
on:
push:
tags:
- 'v*.*.*'
jobs:
build:
name: Build on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-20.04, macos-11]
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
submodules: 'recursive'
- name: Build
run: |
mkdir build
cd build
cmake ..
make
- name: Upload Artifact
uses: actions/upload-artifact@v3
with:
name: fastbe-${{ matrix.os }}
path: build/src/fastbe
release:
needs: build
runs-on: ubuntu-latest
steps:
- name: Download Artifacts
uses: actions/download-artifact@v3
with:
path: artifacts
- name: Display structure
run: ls -R
working-directory: artifacts/
- name: Prepare artifacts
run: |
mv artifacts/fastbe-ubuntu-20.04/fastbe artifacts/fastbe-ubuntu
mv artifacts/fastbe-macos-11/fastbe artifacts/fastbe-macos
- name: Release
uses: softprops/action-gh-release@v1
with:
files: |
artifacts/fastbe-ubuntu
artifacts/fastbe-macos
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}