Skip to content

Commit

Permalink
ci: add release action
Browse files Browse the repository at this point in the history
  • Loading branch information
MR-Addict committed Jan 11, 2024
1 parent 7310a48 commit bd0accd
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: release

on:
push:
tags:
- "v*"
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: docker-practice/actions-setup-docker@master
- uses: actions-rs/toolchain@v1
with:
target: x86_64-unknown-linux-gnu
- name: Install cross
run: |
sudo apt update
sudo apt install build-essential upx-ucl -y
cargo install cross
- name: Cross build
run: |
cross build --target x86_64-unknown-linux-gnu --release
cross build --target x86_64-pc-windows-gnu --release
- name: Compress binaries
run: |
upx --best target/x86_64-unknown-linux-gnu/release/mdbook-embedify
upx --best target/x86_64-pc-windows-gnu/release/mdbook-embedify.exe

0 comments on commit bd0accd

Please sign in to comment.