Building Rubic With GitHub Action π #33
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Rubic Builder | |
run-name: Building Rubic With GitHub Action π | |
on: | |
push: | |
pull_request: | |
branches: | |
- main | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
build: | |
permissions: | |
contents: write | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install Cargo Toolchain | |
run: rustup install nightly | |
- name: Build | |
run: cargo +nightly build --release | |
- name: Generate Commit Hash | |
run: echo ${{ github.sha }} > Release.txt | |
- name: Zip UI for deployment | |
run: tar.exe -a -c -f ui.zip ui/* | |
- name: Generate release tag | |
id: tag | |
run: | | |
echo "::set-output name=release_tag::WindowsRelease_$(date +"%Y.%m.%d_%H-%M")" | |
- name: Publish Release | |
uses: softprops/action-gh-release@v1 | |
with: | |
tag_name: ${{ steps.tag.outputs.release_tag }} | |
files: | | |
target/release/rubic.exe | |
LICENSE | |
Release.txt | |
ui.zip | |
- run: echo "π This job's status is ${{ job.status }}." |