Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

radlc #193

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

radlc #193

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
74 changes: 74 additions & 0 deletions .github/workflows/rust-release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
name: rust release

on:
push:
tags:
- rust/compiler/v[0-9]*

jobs:
build:
name: Build
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-20.04, macos-latest]

steps:
- uses: actions/checkout@v3
# Fetch all history so git describe works
- run: |
git fetch --prune --unshallow

# When rustup is updated, it tries to replace its binary, which on Windows is somehow locked.
# This can result in the CI failure, see: https://github.com/rust-lang/rustup/issues/3029
- run: |
rustup set auto-self-update disable
rustup toolchain install nightly --profile minimal

# caching doesn't work across tags
# https://docs.github.com/en/actions/using-workflows/caching-dependencies-to-speed-up-workflows#restrictions-for-accessing-a-cache
# - uses: Swatinem/rust-cache@v2

- run: cargo +nightly build --release

- uses: actions/upload-artifact@v3
with:
name: radlc-${{ runner.os }}
path: target/release/radlc

release:
name: Create Github Release
needs: [build]
runs-on: ubuntu-latest
steps:

- name: Determine version
id: version
run:
echo "version=${GITHUB_REF:24}" >> $GITHUB_OUTPUT

- name: Fetch macOS build
uses: actions/download-artifact@v3
with:
name: radlc-macOS
path: radlc-macOS

- name: Fetch linux build
uses: actions/download-artifact@v3
with:
name: radlc-Linux
path: radlc-Linux

- run: |
mv radlc-macOS/radlc ./radlc-${{ steps.version.outputs.version }}-osx
mv radlc-Linux/radlc ./radlc-${{ steps.version.outputs.version }}-linux
ls -al

- name: Create Release
id: create_release
uses: softprops/action-gh-release@v1
with:
name: Release rust/compiler ${{ steps.version.outputs.version }}
files: |
radlc-${{ steps.version.outputs.version }}-linux
radlc-${{ steps.version.outputs.version }}-osx
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,5 @@ cpp/runtime/ltmain.sh
cpp/runtime/missing
cpp/runtime/build/
cpp/runtime/test-driver

target/
Loading