Skip to content

Commit 7c900c9

Browse files
committed
Merge #40: Update rbmt to cargo subcommand version
50ea2f6 Update rbmt to cargo subcommand version (Nick Johnson) Pull request description: ACKs for top commit: tcharding: ACK 50ea2f6 Tree-SHA512: 0ff25d017a391560db5228b2edb4481fc32e8cf7ab55f2a59abc1d1e74feda0e04a2afec9b9070d3e8eeac22256ccfec513c88afad9394869db469c00c800c65
2 parents dd6dffc + 50ea2f6 commit 7c900c9

File tree

5 files changed

+20
-29
lines changed

5 files changed

+20
-29
lines changed

.github/workflows/rust.yml

Lines changed: 16 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,15 @@ jobs:
1313
runs-on: ubuntu-latest
1414
outputs:
1515
nightly_version: ${{ steps.read_toolchain.outputs.nightly_version }}
16+
rbmt_version: ${{ steps.read_toolchain.outputs.rbmt_version }}
1617
steps:
1718
- name: "Checkout repo"
1819
uses: actions/checkout@v4
1920
- name: "Read toolchain versions"
2021
id: read_toolchain
21-
run: echo "nightly_version=$(cat nightly-version)" >> $GITHUB_OUTPUT
22+
run: |
23+
echo "nightly_version=$(cat nightly-version)" >> $GITHUB_OUTPUT
24+
echo "rbmt_version=$(cat rbmt-version)" >> $GITHUB_OUTPUT
2225
2326
Stable: # 2 jobs, one per lock file.
2427
name: Test - stable toolchain
@@ -33,9 +36,9 @@ jobs:
3336
- name: "Select toolchain"
3437
uses: dtolnay/rust-toolchain@stable
3538
- name: "Install rbmt"
36-
run: ./contrib/install-rbmt.sh
39+
run: cargo install --git https://github.com/rust-bitcoin/rust-bitcoin-maintainer-tools.git --rev $(cat rbmt-version) cargo-rbmt
3740
- name: "Run tests"
38-
run: rbmt test stable --lock-file ${{ matrix.dep }}
41+
run: cargo rbmt test stable --lock-file ${{ matrix.dep }}
3942

4043
Nightly: # 2 jobs, one per lock file.
4144
name: Test - nightly toolchain
@@ -53,9 +56,9 @@ jobs:
5356
with:
5457
toolchain: ${{ needs.Prepare.outputs.nightly_version }}
5558
- name: "Install rbmt"
56-
run: ./contrib/install-rbmt.sh
59+
run: cargo install --git https://github.com/rust-bitcoin/rust-bitcoin-maintainer-tools.git --rev ${{ needs.Prepare.outputs.rbmt_version }} cargo-rbmt
5760
- name: "Run tests"
58-
run: rbmt test nightly --lock-file ${{ matrix.dep }}
61+
run: cargo rbmt test nightly --lock-file ${{ matrix.dep }}
5962

6063
MSRV: # 2 jobs, one per lock file.
6164
name: Test - MSRV toolchain
@@ -70,13 +73,13 @@ jobs:
7073
- name: "Install stable toolchain"
7174
uses: dtolnay/rust-toolchain@stable
7275
- name: "Install rbmt"
73-
run: ./contrib/install-rbmt.sh
76+
run: cargo install --git https://github.com/rust-bitcoin/rust-bitcoin-maintainer-tools.git --rev $(cat rbmt-version) cargo-rbmt
7477
- name: "Install MSRV toolchain"
7578
uses: dtolnay/rust-toolchain@stable
7679
with:
7780
toolchain: "1.74.0"
7881
- name: "Run tests"
79-
run: rbmt test msrv --lock-file ${{ matrix.dep }}
82+
run: cargo rbmt test msrv --lock-file ${{ matrix.dep }}
8083

8184
Lint:
8285
name: Lint - nightly toolchain
@@ -94,9 +97,9 @@ jobs:
9497
- name: "Install clippy"
9598
run: rustup component add clippy
9699
- name: "Install rbmt"
97-
run: ./contrib/install-rbmt.sh
100+
run: cargo install --git https://github.com/rust-bitcoin/rust-bitcoin-maintainer-tools.git --rev ${{ needs.Prepare.outputs.rbmt_version }} cargo-rbmt
98101
- name: "Run lint"
99-
run: rbmt lint
102+
run: cargo rbmt lint
100103

101104
Docs:
102105
name: Docs - stable toolchain
@@ -109,9 +112,9 @@ jobs:
109112
- name: "Select toolchain"
110113
uses: dtolnay/rust-toolchain@stable
111114
- name: "Install rbmt"
112-
run: ./contrib/install-rbmt.sh
115+
run: cargo install --git https://github.com/rust-bitcoin/rust-bitcoin-maintainer-tools.git --rev $(cat rbmt-version) cargo-rbmt
113116
- name: "Build docs"
114-
run: rbmt docs
117+
run: cargo rbmt docs
115118

116119
Docsrs:
117120
name: Docs - nightly toolchain
@@ -127,9 +130,9 @@ jobs:
127130
with:
128131
toolchain: ${{ needs.Prepare.outputs.nightly_version }}
129132
- name: "Install rbmt"
130-
run: ./contrib/install-rbmt.sh
133+
run: cargo install --git https://github.com/rust-bitcoin/rust-bitcoin-maintainer-tools.git --rev ${{ needs.Prepare.outputs.rbmt_version }} cargo-rbmt
131134
- name: "Build docs.rs docs"
132-
run: rbmt docsrs
135+
run: cargo rbmt docsrs
133136

134137
Format: # 1 job, run cargo fmt directly.
135138
name: Format - nightly toolchain

contrib/install-rbmt.sh

Lines changed: 0 additions & 12 deletions
This file was deleted.

justfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ _default:
66

77
# Install rbmt (Rust Bitcoin Maintainer Tools).
88
@_install-rbmt:
9-
rustup run stable {{justfile_directory()}}/contrib/install-rbmt.sh
9+
cargo install --quiet --git https://github.com/rust-bitcoin/rust-bitcoin-maintainer-tools.git --rev $(cat {{justfile_directory()}}/rbmt-version) cargo-rbmt
1010

1111
# Cargo check everything.
1212
check:
@@ -36,12 +36,12 @@ docsrs *flags:
3636
# Update the recent and minimal lock files using rbmt.
3737
[group('tools')]
3838
@update-lock-files: _install-rbmt
39-
rustup run {{NIGHTLY_VERSION}} rbmt lock
39+
rustup run {{NIGHTLY_VERSION}} cargo rbmt lock
4040

4141
# Run CI tasks with rbmt.
4242
[group('ci')]
4343
@ci task toolchain="stable" lock="recent": _install-rbmt
44-
RBMT_LOG_LEVEL=quiet rustup run {{toolchain}} rbmt --lock-file {{lock}} {{task}}
44+
RBMT_LOG_LEVEL=quiet rustup run {{toolchain}} cargo rbmt --lock-file {{lock}} {{task}}
4545

4646
# Test crate.
4747
[group('ci')]

rbmt-version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
4eb8e3b752288a3ac9b24aa94fc4c29a532644af
1+
95a2fd3300933a531f89488a08ddb6df9c9561ab
File renamed without changes.

0 commit comments

Comments
 (0)