Skip to content

Commit 0305abd

Browse files
committed
Merge #503: CI cleanup
8c48538 Clean up DO_NO_STD usage (Tobin C. Harding) cc32761 Use 1.58.0 directly (Tobin C. Harding) 1a098ad Fix spelling mistake it CI job (Tobin C. Harding) 5705902 Remove DO_NO_STD from fuzz job (Tobin C. Harding) 8b85649 Remove MSRV local variable (Tobin C. Harding) 2edc456 Remove --all flag (Tobin C. Harding) 1a09248 Remove flags from shebang line (Tobin C. Harding) Pull request description: Do a bunch of cleanups to the CI script and GitHub Actions config file. None of these changes change the amount of test coverage but we do achieve some de-duplication of test runs. Otherwise, clean up only. ACKs for top commit: apoelstra: ACK 8c48538 Tree-SHA512: bd0e1f81a5c39a8c79d789fc42235014cd4f69af612c6b49f549a826ff4b5d93fd09b9ea1a49229ca0bcff50d940d2d97d6eab43f3280fbb4b17bd2d836fdd9f
2 parents b809ab5 + 8c48538 commit 0305abd

File tree

2 files changed

+12
-24
lines changed

2 files changed

+12
-24
lines changed

.github/workflows/rust.yml

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,25 +6,20 @@ jobs:
66
Fuzz:
77
name: Fuzz
88
runs-on: ubuntu-latest
9-
strategy:
10-
matrix:
11-
rust:
12-
- 1.58.0
139
steps:
1410
- name: Checkout Crate
1511
uses: actions/checkout@v2
16-
- name: Install hongfuzz dependancies
12+
- name: Install hongfuzz dependencies
1713
run: sudo apt update && sudo apt install build-essential binutils-dev libunwind-dev libblocksruntime-dev liblzma-dev
1814
- name: Checkout Toolchain
1915
uses: actions-rs/toolchain@v1
2016
with:
2117
profile: minimal
22-
toolchain: ${{ matrix.rust }}
18+
toolchain: 1.58.0
2319
override: true
2420
- name: Running fuzzer
2521
env:
2622
DO_FUZZ: true
27-
DO_NO_STD: true
2823
run: ./contrib/test.sh
2924

3025
Nightly:
@@ -42,7 +37,6 @@ jobs:
4237
- name: Running benchmarks
4338
env:
4439
DO_BENCH: true
45-
DO_NO_STD: true
4640
run: ./contrib/test.sh
4741
- name: Building docs
4842
env:
@@ -64,7 +58,6 @@ jobs:
6458
- rust: nightly
6559
- rust: 1.41.1
6660
- rust: 1.47
67-
DO_NO_STD: true
6861
steps:
6962
- name: Checkout Crate
7063
uses: actions/checkout@v2
@@ -77,7 +70,7 @@ jobs:
7770
- name: Running cargo
7871
env:
7972
DO_FEATURE_MATRIX: true
80-
DO_NO_STD: ${{ matrix.DO_NO_STD }}
73+
DO_NO_STD: true
8174
run: ./contrib/test.sh
8275

8376
Embedded:

contrib/test.sh

Lines changed: 9 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
#!/bin/sh -ex
1+
#!/bin/sh
22

3-
set -e
3+
set -ex
44

55
FEATURES="compiler serde rand"
66

@@ -10,28 +10,23 @@ cargo update -p serde_derive --precise 1.0.142
1010
cargo --version
1111
rustc --version
1212

13-
# Work out if we are using a nightly toolchain.
14-
MSRV=false
13+
# Pin dependencies required to build with Rust 1.41.1
1514
if cargo --version | grep "1\.41\.0"; then
16-
MSRV=true
17-
fi
18-
19-
if cargo --version | grep "1\.47\.0"; then
15+
cargo update -p url --precise 2.2.2
16+
cargo update -p form_urlencoded --precise 1.0.1
2017
cargo update -p once_cell --precise 1.13.1
2118
fi
2219

23-
# form_urlencoded 1.1.0 breaks MSRV.
24-
if [ "$MSRV" = true ]; then
25-
cargo update -p url --precise 2.2.2
26-
cargo update -p form_urlencoded --precise 1.0.1
20+
# Pin dependencies required to build with Rust 1.47.0
21+
if cargo --version | grep "1\.47\.0"; then
2722
cargo update -p once_cell --precise 1.13.1
2823
fi
2924

3025
# Format if told to
3126
if [ "$DO_FMT" = true ]
3227
then
3328
rustup component add rustfmt
34-
cargo fmt --all -- --check
29+
cargo fmt -- --check
3530
fi
3631

3732
# Fuzz if told to
@@ -97,7 +92,7 @@ fi
9792

9893
# Build the docs if told to (this only works with the nightly toolchain)
9994
if [ "$DO_DOCS" = true ]; then
100-
RUSTDOCFLAGS="--cfg docsrs" cargo doc --all --features="$FEATURES"
95+
RUSTDOCFLAGS="--cfg docsrs" cargo doc --features="$FEATURES"
10196
fi
10297

10398
exit 0

0 commit comments

Comments
 (0)