Skip to content

Commit

Permalink
Updated release.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
nimaaskarian committed Feb 1, 2024
1 parent b59ebc7 commit eb2518a
Showing 1 changed file with 14 additions and 38 deletions.
52 changes: 14 additions & 38 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,48 +1,24 @@
name: Release

on:
push:
tags:
- '*'

jobs:
build-and-release:
build:
name: Release
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Set up Rust
uses: actions/setup-rust@v1

- name: Build for Linux
run: cargo build --release --target x86_64-unknown-linux-gnu

- name: Build for Windows
run: cargo build --release --target x86_64-pc-windows-msvc

- name: Create release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
body: |
Changes in this release.
draft: false
prerelease: false

- name: Upload Linux build
uses: actions/upload-artifact@v2
- uses: actions/checkout@master
- name: Compile
id: compile
uses: rust-build/[email protected]
with:
name: c3.x86.linux
path: target/x86_64-unknown-linux-gnu/release/c3

- name: Upload Windows build
uses: actions/upload-artifact@v2
RUSTTARGET: x86_64-unknown-linux-musl
UPLOAD_MODE: none
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: c3.x86_64.windows.exe
path: target/x86_64-pc-windows-msvc/release/c3
name: Binary
path: |
${{ steps.compile.outputs.BUILT_ARCHIVE }}
${{ steps.compile.outputs.BUILT_CHECKSUM }}

0 comments on commit eb2518a

Please sign in to comment.