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

Add cargo package check job in release workflow #109

Merged
merged 1 commit into from
Mar 15, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 45 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
run: |
cargo install --locked wasm-pack

- name: Build
- name: Build binaries
run: |
cargo build --target=${{ matrix.target }} --release --locked

Expand All @@ -69,9 +69,52 @@ jobs:
if-no-files-found: error
path: ./bin/

package:
runs-on: ubuntu-22.04

steps:
- uses: actions/[email protected]

- name: install apt depenedencies
run: |
sudo apt-get update
sudo apt-get install -y musl-tools

- name: Install Protoc
uses: arduino/setup-protoc@v1
with:
version: '3.x'
repo-token: ${{ secrets.GITHUB_TOKEN }}

- name: Get Rust toolchain
id: toolchain
working-directory: .
run: |
awk -F'[ ="]+' '$1 == "channel" { print "toolchain=" $2 }' rust-toolchain >> "$GITHUB_OUTPUT"

- uses: dtolnay/rust-toolchain@v1
with:
toolchain: ${{ steps.toolchain.outputs.toolchain }}

- uses: Swatinem/[email protected]

- name: install cargo-about
run: |
cargo install --locked cargo-about

- name: Install wasm-pack
run: |
cargo install --locked wasm-pack

- name: package
run: |
cargo package

# TODO: cargo publish

release:
name: Release
needs: [ build ]
needs: [ build, package ]
permissions:
contents: write

Expand Down
Loading