chore(deps): bump tonic from 0.9.2 to 0.12.3 #1155
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: CI | |
on: | |
push: | |
branches: ["main"] | |
pull_request: | |
branches: ["main"] | |
env: | |
CARGO_TERM_COLOR: always | |
CICD_INTERMEDIATES_DIR: "_cicd-intermediates" | |
WUKONG_HONEYCOMB_API_KEY: ${{ secrets.WUKONG_HONEYCOMB_API_KEY }} | |
CI: true | |
jobs: | |
check-formatting-clippy: | |
name: Check Formatting and Clippy | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
submodules: "recursive" | |
- name: Setup Rust | |
uses: dtolnay/rust-toolchain@stable | |
with: | |
components: rustfmt, clippy | |
- name: Check formatting | |
uses: actions-rs/cargo@v1 | |
with: | |
command: fmt | |
args: --all -- --check | |
- name: Install protoc for Linux | |
shell: bash | |
run: | | |
sudo apt -y update | |
sudo curl -sSLO https://github.com/protocolbuffers/protobuf/releases/download/v22.3/protoc-22.3-linux-x86_64.zip | |
sudo unzip protoc-22.3-linux-x86_64.zip -d /usr | |
protoc --version | |
- name: Check clippy | |
uses: actions-rs/cargo@v1 | |
with: | |
command: clippy | |
args: -- -D warnings | |
- name: Test Wukong CLI | |
uses: actions-rs/cargo@v1 | |
with: | |
command: test | |
args: --verbose | |
ci: | |
strategy: | |
fail-fast: false | |
matrix: | |
rust: [stable] | |
job: | |
- { | |
name: "macOS-arm", | |
target: aarch64-apple-darwin, | |
os: macos-latest, | |
} | |
- { name: "macOS-x86", target: x86_64-apple-darwin, os: macos-latest } | |
- { | |
name: "linux-x86", | |
target: x86_64-unknown-linux-gnu, | |
os: ubuntu-22.04, | |
use-cross: true, | |
} | |
- { | |
name: "linux-x86-musl", | |
target: x86_64-unknown-linux-musl, | |
os: ubuntu-22.04, | |
use-cross: true, | |
} | |
name: ${{ matrix.job.name }} (${{ matrix.job.target }}) | |
runs-on: ${{ matrix.job.os }} | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
submodules: "recursive" | |
- name: Setup Rust | |
uses: actions-rs/toolchain@v1 | |
with: | |
profile: minimal | |
toolchain: ${{ matrix.rust }} | |
target: ${{ matrix.job.target }} | |
components: rustfmt, clippy | |
override: true | |
- name: Install protoc for Linux | |
if: contains(matrix.job.target, 'linux') | |
shell: bash | |
run: | | |
sudo apt -y update | |
sudo curl -sSLO https://github.com/protocolbuffers/protobuf/releases/download/v22.3/protoc-22.3-linux-x86_64.zip | |
sudo unzip protoc-22.3-linux-x86_64.zip -d /usr | |
which protoc | |
- name: Install protoc for macOS | |
if: contains(matrix.job.target, 'apple-darwin') | |
shell: bash | |
run: | | |
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" | |
brew install protobuf | |
protoc --version | |
- name: Extract crate information | |
shell: bash | |
run: | | |
echo "PROJECT_NAME=$(sed -n 's/^name = "\(.*\)"/\1/p' Cargo.toml | head -n1)" >> $GITHUB_ENV | |
echo "PROJECT_VERSION=$(sed -n 's/^version = "\(.*\)"/\1/p' Cargo.toml | head -n1)" >> $GITHUB_ENV | |
echo "PROJECT_MAINTAINER=$(sed -n 's/^authors = \["\(.*\)"\]/\1/p' Cargo.toml)" >> $GITHUB_ENV | |
echo "PROJECT_HOMEPAGE=$(sed -n 's/^homepage = "\(.*\)"/\1/p' Cargo.toml)" >> $GITHUB_ENV | |
- name: Build Wukong CLI | |
uses: actions-rs/cargo@v1 | |
with: | |
use-cross: ${{ matrix.job.use-cross }} | |
command: build | |
args: --locked --features prod --release --target=${{ matrix.job.target }} |