-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
GitHub action for publishing release
- Loading branch information
Showing
1 changed file
with
52 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
name: Release | ||
|
||
on: | ||
push: | ||
tags: | ||
- "v*.*.*" | ||
|
||
jobs: | ||
release-linux: | ||
name: Build binaries (linux) and publish on crates.io | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
- name: Install rust stable | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: stable | ||
default: true | ||
profile: minimal | ||
components: rust-docs | ||
- name: Build release | ||
working-directory: hlbc-cli | ||
run: cargo build --release | ||
- name: Upload release artifact | ||
uses: softprops/action-gh-release@v1 | ||
with: | ||
files: target/release/hlbc-cli | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
release-windows: | ||
name: Build binaries (windows) | ||
runs-on: windows-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
- name: Install rust stable | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: stable | ||
default: true | ||
profile: minimal | ||
components: rust-docs | ||
- name: Build release | ||
working-directory: hlbc-cli | ||
run: cargo build --release | ||
- name: Upload release artifact | ||
uses: softprops/action-gh-release@v1 | ||
with: | ||
files: target/release/hlbc-cli.exe | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |