Skip to content

Build artifacts

Build artifacts #113

Workflow file for this run

name: Build artifacts
on:
push:
tags:
- '*'
workflow_dispatch:
jobs:
build:
strategy:
matrix:
os: [macos-latest ubuntu-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- uses: goto-bus-stop/setup-zig@v2
- name: install dependencies (apt)
if: ${{ startsWith(${{ matrix.os }}, 'ubuntu') }}

Check failure on line 20 in .github/workflows/build.yml

View workflow run for this annotation

GitHub Actions / Build artifacts

Invalid workflow file

The workflow is not valid. .github/workflows/build.yml (Line: 20, Col: 13): Unexpected symbol: '${{'. Located at position 12 within expression: startsWith(${{ matrix.os .github/workflows/build.yml (Line: 26, Col: 13): Unexpected symbol: '${{'. Located at position 12 within expression: startsWith(${{ matrix.os
run: |
sudo apt-get update
sudo apt-get install \
libnotcurses-core-dev lua5.4
- name: Set up homebrew
if: $${{ startsWith(${{ matrix.os }}, 'macos') }}
id: set-up-homebrew
uses: Homebrew/actions/setup-homebrew@master
- name: install dependencies (homebrew)
if: $${{ startsWith(${{ matrix.os }}, 'macos') }}
run: |
brew install pkg-config lua notcurses
- name: build seamstress
run: |
zig build -Doptimize=ReleaseSafe --summary all
- name: zip artifact
run: |
cd zig-out/ && tar -czvf ../seamstress-${{ matrix.os }}-x86_64-${{ github.ref_name }}.tar.gz .
- uses: actions/upload-artifact@v2
with:
name: ${{ matrix.os }}-${{ github.ref_name }}
path: |
./*.tar.gz
release:
runs-on: ubuntu-latest
needs: [build]
steps:
- uses: actions/checkout@v3
- uses: actions/download-artifact@v3
- uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
draft: true
files: |
./macos-latest-x86_64-${{ github.ref_name }}/*.tar.gz
./ubuntu-latest-x86_64-${{ github.ref_name }}/*.tar.gz