Use action-rs/toolchain in CI
This commit is contained in:
parent
0ba41c5751
commit
dfcbafd6b1
18
.github/workflows/code_coverage.yml
vendored
18
.github/workflows/code_coverage.yml
vendored
@ -16,16 +16,13 @@ jobs:
|
|||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
- name: Install lcov tools
|
- name: Install lcov tools
|
||||||
run: sudo apt-get install lcov -y
|
run: sudo apt-get install lcov -y
|
||||||
- name: Install rustup
|
- name: Install Rust toolchain
|
||||||
run: curl https://sh.rustup.rs -sSf | sh -s -- -y
|
uses: actions-rs/toolchain@v1
|
||||||
- name: Set default toolchain
|
with:
|
||||||
run: rustup default nightly
|
toolchain: "1.65.0"
|
||||||
- name: Set profile
|
override: true
|
||||||
run: rustup set profile minimal
|
profile: minimal
|
||||||
- name: Add llvm tools
|
components: llvm-tools-preview
|
||||||
run: rustup component add llvm-tools-preview
|
|
||||||
- name: Update toolchain
|
|
||||||
run: rustup update
|
|
||||||
- name: Cache cargo
|
- name: Cache cargo
|
||||||
uses: actions/cache@v3
|
uses: actions/cache@v3
|
||||||
with:
|
with:
|
||||||
@ -53,7 +50,6 @@ jobs:
|
|||||||
run: mkdir coverage; grcov . --binary-path ./target/debug/ -s . -t lcov --branch --ignore-not-existing --ignore '/*' -o ./coverage/lcov.info
|
run: mkdir coverage; grcov . --binary-path ./target/debug/ -s . -t lcov --branch --ignore-not-existing --ignore '/*' -o ./coverage/lcov.info
|
||||||
- name: Generate HTML coverage report
|
- name: Generate HTML coverage report
|
||||||
run: genhtml -o coverage-report.html ./coverage/lcov.info
|
run: genhtml -o coverage-report.html ./coverage/lcov.info
|
||||||
|
|
||||||
- name: Coveralls upload
|
- name: Coveralls upload
|
||||||
uses: coverallsapp/github-action@master
|
uses: coverallsapp/github-action@master
|
||||||
with:
|
with:
|
||||||
|
46
.github/workflows/cont_integration.yml
vendored
46
.github/workflows/cont_integration.yml
vendored
@ -30,15 +30,13 @@ jobs:
|
|||||||
~/.cargo/git
|
~/.cargo/git
|
||||||
target
|
target
|
||||||
key: ${{ runner.os }}-cargo-${{ hashFiles('.cache_key') }}-${{ hashFiles('**/Cargo.toml','**/Cargo.lock') }}
|
key: ${{ runner.os }}-cargo-${{ hashFiles('.cache_key') }}-${{ hashFiles('**/Cargo.toml','**/Cargo.lock') }}
|
||||||
- name: Set default toolchain
|
- name: Install Rust toolchain
|
||||||
run: rustup default ${{ matrix.rust.version }}
|
uses: actions-rs/toolchain@v1
|
||||||
- name: Set profile
|
with:
|
||||||
run: rustup set profile minimal
|
toolchain: ${{ matrix.rust.version }}
|
||||||
- name: Add clippy
|
override: true
|
||||||
if: ${{ matrix.rust.clippy }}
|
components: clippy
|
||||||
run: rustup component add clippy
|
profile: minimal
|
||||||
- name: Update toolchain
|
|
||||||
run: rustup update
|
|
||||||
- name: Build
|
- name: Build
|
||||||
run: cargo build ${{ matrix.features }}
|
run: cargo build ${{ matrix.features }}
|
||||||
- name: Clippy
|
- name: Clippy
|
||||||
@ -69,14 +67,13 @@ jobs:
|
|||||||
- run: sudo apt-add-repository "deb http://apt.llvm.org/focal/ llvm-toolchain-focal-10 main" || exit 1
|
- run: sudo apt-add-repository "deb http://apt.llvm.org/focal/ llvm-toolchain-focal-10 main" || exit 1
|
||||||
- run: sudo apt-get update || exit 1
|
- run: sudo apt-get update || exit 1
|
||||||
- run: sudo apt-get install -y libclang-common-10-dev clang-10 libc6-dev-i386 || exit 1
|
- run: sudo apt-get install -y libclang-common-10-dev clang-10 libc6-dev-i386 || exit 1
|
||||||
- name: Set default toolchain
|
- name: Install Rust toolchain
|
||||||
run: rustup default 1.65.0 # STABLE
|
uses: actions-rs/toolchain@v1
|
||||||
- name: Set profile
|
with:
|
||||||
run: rustup set profile minimal
|
toolchain: "1.65.0"
|
||||||
- name: Add target wasm32
|
override: true
|
||||||
run: rustup target add wasm32-unknown-unknown
|
profile: minimal
|
||||||
- name: Update toolchain
|
target: "wasm32-unknown-unknown"
|
||||||
run: rustup update
|
|
||||||
- name: Check bdk
|
- name: Check bdk
|
||||||
working-directory: ./crates/bdk
|
working-directory: ./crates/bdk
|
||||||
run: cargo check --target wasm32-unknown-unknown --features dev-getrandom-wasm
|
run: cargo check --target wasm32-unknown-unknown --features dev-getrandom-wasm
|
||||||
@ -90,13 +87,12 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
- name: Set default toolchain
|
- name: Install Rust toolchain
|
||||||
run: rustup default nightly
|
uses: actions-rs/toolchain@v1
|
||||||
- name: Set profile
|
with:
|
||||||
run: rustup set profile minimal
|
toolchain: "1.65.0"
|
||||||
- name: Add rustfmt
|
override: true
|
||||||
run: rustup component add rustfmt
|
profile: minimal
|
||||||
- name: Update toolchain
|
components: rustfmt
|
||||||
run: rustup update
|
|
||||||
- name: Check fmt
|
- name: Check fmt
|
||||||
run: cargo fmt --all -- --config format_code_in_doc_comments=true --check
|
run: cargo fmt --all -- --config format_code_in_doc_comments=true --check
|
||||||
|
Loading…
x
Reference in New Issue
Block a user