ShadowySpirits commented on code in PR #490:
URL: https://github.com/apache/rocketmq-clients/pull/490#discussion_r1174319397
##########
.github/workflows/rust_build.yml:
##########
@@ -2,27 +2,114 @@ name: Rust Build
on:
workflow_call:
jobs:
+ fmt-check:
+ runs-on: ubuntu-latest
+ name: fmt
+ steps:
+ - uses: actions/checkout@v3
+ with:
+ submodules: true
+ - name: Install stable
+ uses: actions-rs/toolchain@v1
+ with:
+ toolchain: stable
+ components: rustfmt
+ - name: Code format check
+ working-directory: ./rust
+ run: cargo fmt --check
+ clippy-check:
+ runs-on: ubuntu-latest
+ name: clippy
+ permissions: write-all
+ strategy:
+ fail-fast: false
+ steps:
+ - uses: actions/checkout@v3
+ with:
+ submodules: true
+ - name: Install stable
+ uses: actions-rs/toolchain@v1
+ with:
+ toolchain: stable
+ components: clippy
+ - name: Install protoc
+ uses: arduino/setup-protoc@v1
+ with:
+ version: '3.x'
+ repo-token: ${{ secrets.GITHUB_TOKEN }}
+ - name: Clippy check
+ uses: actions-rs/clippy-check@v1
+ with:
+ token: ${{ secrets.GITHUB_TOKEN }}
+ args: --all-features --manifest-path rust/Cargo.toml -- -D warnings
+ doc-check:
+ runs-on: ubuntu-latest
+ name: doc
+ steps:
+ - uses: actions/checkout@v3
+ with:
+ submodules: true
+ - name: Install stable
+ uses: actions-rs/toolchain@v1
+ with:
+ toolchain: stable
+ - name: Install protoc
+ uses: arduino/setup-protoc@v1
+ with:
+ version: '3.x'
+ repo-token: ${{ secrets.GITHUB_TOKEN }}
+ - name: Build doc
+ working-directory: ./rust
+ run: cargo doc --no-deps --all-features
+ env:
+ RUSTDOCFLAGS: --cfg docsrs
+ msrv-check:
+ runs-on: ubuntu-latest
+ strategy:
+ matrix:
+ msrv: [1.61]
+ name: msrv / ${{ matrix.msrv }}
+ steps:
+ - uses: actions/checkout@v3
+ with:
+ submodules: true
+ - name: Install ${{ matrix.msrv }}
+ uses: actions-rs/toolchain@v1
+ with:
+ toolchain: ${{ matrix.msrv }}
+ - name: Install protoc
+ uses: arduino/setup-protoc@v1
+ with:
+ version: '3.x'
+ repo-token: ${{ secrets.GITHUB_TOKEN }}
+ - name: Check MSRV ${{ matrix.msrv }}
+ working-directory: ./rust
+ run: cp Cargo.minimal.lock Cargo.lock && cargo +${{ matrix.msrv }}
check --locked
Review Comment:
Our sdk lib is integrated by other application, so that pin the version of
dependencies is not a good choice.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]