Skip to content

Keep macos-latest-xlarge only (#16) #3

Keep macos-latest-xlarge only (#16)

Keep macos-latest-xlarge only (#16) #3

name: Build and release artifacts
on:
push:
branches:
- release
permissions:
contents: write
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-20.04, macos-latest-xlarge]
steps:
- name: Free Disk Space (Ubuntu)
if: matrix.os == 'ubuntu-20.04'
uses: jlumbroso/free-disk-space@main
with:
tool-cache: true
android: true
dotnet: true
haskell: true
large-packages: true
docker-images: true
swap-storage: true
- uses: actions/checkout@v4
- name: Install ninja
if: matrix.os == 'ubuntu-20.04'
run: |
sudo apt update
sudo apt-get -y install ninja-build
- name: Install ninja
if: contains(matrix.os, 'macos')
run: |
brew install ninja
- name: Download source
run: ./clone.sh
- name: Apply patches
run: ./patch.sh
- name: Build toolchain
run: ./build.sh
# Push in the Github environment variable the name of the artifact
# Doing this now because in the following step the rust folder will
# be delated to save some space before installing the toolchain
- run: ./config.sh -artifact_name
- name: Package toolchain
run: ./package.sh
- name: Release
uses: ncipollo/release-action@v1
with:
artifacts: "${{ env.ARTIFACT_NAME }}.tar.zst"
tag: "${{ env.ARTIFACT_NAME }}"
name: "${{ env.ARTIFACT_NAME }}"