@@ -72,20 +72,10 @@ jobs:
72
72
shell : bash
73
73
run : |
74
74
if [[ ${{ github.event_name }} == 'schedule' ]]; then
75
- RUSTC_HASH=$(git ls-remote https://github.com/rust-lang/rust.git master | awk '{print $1}')
75
+ ./rustup-toolchain HEAD --host ${{ matrix.host_target }}
76
76
else
77
- RUSTC_HASH=$(< rust-version)
77
+ ./rustup-toolchain "" --host ${{ matrix.host_target }}
78
78
fi
79
- # We need a nightly cargo for parts of the cargo miri test suite.
80
- rustup-toolchain-install-master \
81
- -f \
82
- -n master "$RUSTC_HASH" \
83
- -c cargo \
84
- -c rust-src \
85
- -c rustc-dev \
86
- -c llvm-tools \
87
- --host ${{ matrix.host_target }}
88
- rustup default master
89
79
90
80
- name : Show Rust version
91
81
run : |
@@ -97,26 +87,35 @@ jobs:
97
87
run : bash ./ci.sh
98
88
99
89
fmt :
100
- name : check formatting (ignored by bors)
90
+ name : formatting (ignored by bors)
101
91
runs-on : ubuntu-latest
102
92
steps :
103
93
- uses : actions/checkout@v3
104
94
- name : Install latest nightly
105
- uses : actions-rs/toolchain@v1
106
- with :
107
- toolchain : nightly
108
- components : rustfmt
109
- default : true
110
- - name : Check formatting (miri)
111
- uses : actions-rs/cargo@v1
112
- with :
113
- command : fmt
114
- args : --all -- --check
115
- - name : Check formatting (cargo-miri)
116
- uses : actions-rs/cargo@v1
117
- with :
118
- command : fmt
119
- args : --manifest-path cargo-miri/Cargo.toml --all -- --check
95
+ run : |
96
+ rustup toolchain install nightly --component rustfmt
97
+ rustup override set nightly
98
+ - name : Formatting (miri, ui_test)
99
+ run : cargo fmt --all --check
100
+ - name : Formatting (cargo-miri)
101
+ run : cargo fmt --manifest-path cargo-miri/Cargo.toml --all --check
102
+
103
+ clippy :
104
+ name : clippy (ignored by bors)
105
+ runs-on : ubuntu-latest
106
+ steps :
107
+ - uses : actions/checkout@v3
108
+ - name : Install required toolchain
109
+ # We need a toolchain that can actually build Miri, just a nightly won't do.
110
+ run : |
111
+ cargo install rustup-toolchain-install-master # TODO: cache this?
112
+ ./rustup-toolchain "" -c clippy
113
+ - name : Clippy (miri)
114
+ run : cargo clippy --all-targets -- -D warnings
115
+ # - name: Clippy (ui_test)
116
+ # run: cargo clippy --manifest-path ui_test/Cargo.toml --all-targets -- -D warnings
117
+ - name : Clippy (cargo-miri)
118
+ run : cargo clippy --manifest-path cargo-miri/Cargo.toml --all-targets -- -D warnings
120
119
121
120
# These jobs doesn't actually test anything, but they're only used to tell
122
121
# bors the build completed, as there is no practical way to detect when a
0 commit comments