Skip to content

Commit 36e3c41

Browse files
committed
Auto merge of #6149 - flip1995:update_actions, r=ebroto
Remove deprecated set-env from GHA This updates all of our action dependencies and removes every usage of `set-env`. `set-env` and `add-path` has been deprecated: https://github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands/ changelog: none
2 parents ed2b457 + c4c9453 commit 36e3c41

File tree

5 files changed

+26
-31
lines changed

5 files changed

+26
-31
lines changed

.github/workflows/clippy.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -36,14 +36,14 @@ jobs:
3636
github_token: "${{ secrets.github_token }}"
3737

3838
- name: rust-toolchain
39-
uses: actions-rs/[email protected].3
39+
uses: actions-rs/[email protected].6
4040
with:
4141
toolchain: nightly
4242
target: x86_64-unknown-linux-gnu
4343
profile: minimal
4444

4545
- name: Checkout
46-
uses: actions/checkout@v2.0.0
46+
uses: actions/checkout@v2.3.3
4747

4848
- name: Run cargo update
4949
run: cargo update
@@ -63,7 +63,7 @@ jobs:
6363
- name: Set LD_LIBRARY_PATH (Linux)
6464
run: |
6565
SYSROOT=$(rustc --print sysroot)
66-
echo "::set-env name=LD_LIBRARY_PATH::${SYSROOT}/lib${LD_LIBRARY_PATH+:${LD_LIBRARY_PATH}}"
66+
echo "LD_LIBRARY_PATH=${SYSROOT}/lib${LD_LIBRARY_PATH+:${LD_LIBRARY_PATH}}" >> $GITHUB_ENV
6767
6868
- name: Build
6969
run: cargo build --features deny-warnings

.github/workflows/clippy_bors.yml

+15-20
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ env:
1111
CARGO_TARGET_DIR: '${{ github.workspace }}/target'
1212
NO_FMT_TEST: 1
1313

14+
defaults:
15+
run:
16+
shell: bash
17+
1418
jobs:
1519
changelog:
1620
runs-on: ubuntu-latest
@@ -20,7 +24,7 @@ jobs:
2024
with:
2125
github_token: "${{ secrets.github_token }}"
2226
- name: Checkout
23-
uses: actions/checkout@v2.0.0
27+
uses: actions/checkout@v2.3.3
2428
with:
2529
ref: ${{ github.ref }}
2630

@@ -81,14 +85,14 @@ jobs:
8185
if: matrix.host == 'i686-unknown-linux-gnu'
8286

8387
- name: rust-toolchain
84-
uses: actions-rs/[email protected].3
88+
uses: actions-rs/[email protected].6
8589
with:
8690
toolchain: nightly
8791
target: ${{ matrix.host }}
8892
profile: minimal
8993

9094
- name: Checkout
91-
uses: actions/checkout@v2.0.0
95+
uses: actions/checkout@v2.3.3
9296

9397
- name: Run cargo update
9498
run: cargo update
@@ -105,14 +109,13 @@ jobs:
105109
run: bash setup-toolchain.sh
106110
env:
107111
HOST_TOOLCHAIN: ${{ matrix.host }}
108-
shell: bash
109112

110113
# Run
111114
- name: Set LD_LIBRARY_PATH (Linux)
112115
if: runner.os == 'Linux'
113116
run: |
114117
SYSROOT=$(rustc --print sysroot)
115-
echo "::set-env name=LD_LIBRARY_PATH::${SYSROOT}/lib${LD_LIBRARY_PATH+:${LD_LIBRARY_PATH}}"
118+
echo "LD_LIBRARY_PATH=${SYSROOT}/lib${LD_LIBRARY_PATH+:${LD_LIBRARY_PATH}}" >> $GITHUB_ENV
116119
- name: Link rustc dylib (MacOS)
117120
if: runner.os == 'macOS'
118121
run: |
@@ -122,41 +125,33 @@ jobs:
122125
- name: Set PATH (Windows)
123126
if: runner.os == 'Windows'
124127
run: |
125-
$sysroot = rustc --print sysroot
126-
$env:PATH += ';' + $sysroot + '\bin'
127-
echo "::set-env name=PATH::$env:PATH"
128+
SYSROOT=$(rustc --print sysroot)
129+
echo "$SYSROOT/bin" >> $GITHUB_PATH
128130
129131
- name: Build
130132
run: cargo build --features deny-warnings
131-
shell: bash
132133

133134
- name: Test
134135
run: cargo test --features deny-warnings
135-
shell: bash
136136

137137
- name: Test clippy_lints
138138
run: cargo test --features deny-warnings
139-
shell: bash
140139
working-directory: clippy_lints
141140

142141
- name: Test rustc_tools_util
143142
run: cargo test --features deny-warnings
144-
shell: bash
145143
working-directory: rustc_tools_util
146144

147145
- name: Test clippy_dev
148146
run: cargo test --features deny-warnings
149-
shell: bash
150147
working-directory: clippy_dev
151148

152149
- name: Test cargo-clippy
153150
run: ../target/debug/cargo-clippy
154-
shell: bash
155151
working-directory: clippy_workspace_tests
156152

157153
- name: Test clippy-driver
158154
run: bash .github/driver.sh
159-
shell: bash
160155
env:
161156
OS: ${{ runner.os }}
162157

@@ -165,7 +160,7 @@ jobs:
165160
run: |
166161
cargo +nightly install cargo-cache --no-default-features --features ci-autoclean cargo-cache
167162
cargo cache
168-
shell: bash
163+
169164
integration_build:
170165
needs: changelog
171166
runs-on: ubuntu-latest
@@ -177,14 +172,14 @@ jobs:
177172
github_token: "${{ secrets.github_token }}"
178173

179174
- name: rust-toolchain
180-
uses: actions-rs/[email protected].3
175+
uses: actions-rs/[email protected].6
181176
with:
182177
toolchain: nightly
183178
target: x86_64-unknown-linux-gnu
184179
profile: minimal
185180

186181
- name: Checkout
187-
uses: actions/checkout@v2.0.0
182+
uses: actions/checkout@v2.3.3
188183

189184
- name: Run cargo update
190185
run: cargo update
@@ -258,14 +253,14 @@ jobs:
258253
github_token: "${{ secrets.github_token }}"
259254

260255
- name: rust-toolchain
261-
uses: actions-rs/[email protected].3
256+
uses: actions-rs/[email protected].6
262257
with:
263258
toolchain: nightly
264259
target: x86_64-unknown-linux-gnu
265260
profile: minimal
266261

267262
- name: Checkout
268-
uses: actions/checkout@v2.0.0
263+
uses: actions/checkout@v2.3.3
269264

270265
- name: Run cargo update
271266
run: cargo update

.github/workflows/clippy_dev.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,15 @@ jobs:
2323
steps:
2424
# Setup
2525
- name: rust-toolchain
26-
uses: actions-rs/[email protected].3
26+
uses: actions-rs/[email protected].6
2727
with:
2828
toolchain: nightly
2929
target: x86_64-unknown-linux-gnu
3030
profile: minimal
3131
components: rustfmt
3232

3333
- name: Checkout
34-
uses: actions/checkout@v2.0.0
34+
uses: actions/checkout@v2.3.3
3535

3636
# Run
3737
- name: Build

.github/workflows/deploy.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,10 @@ jobs:
2121
steps:
2222
# Setup
2323
- name: Checkout
24-
uses: actions/checkout@v2.0.0
24+
uses: actions/checkout@v2.3.3
2525

2626
- name: Checkout
27-
uses: actions/checkout@v2.0.0
27+
uses: actions/checkout@v2.3.3
2828
with:
2929
ref: ${{ env.TARGET_BRANCH }}
3030
path: 'out'
@@ -34,10 +34,10 @@ jobs:
3434
if: startswith(github.ref, 'refs/tags/')
3535
run: |
3636
TAG=$(basename ${{ github.ref }})
37-
echo "::set-env name=TAG_NAME::$TAG"
37+
echo "TAG_NAME=$TAG" >> $GITHUB_ENV
3838
- name: Set beta to true
3939
if: github.ref == 'refs/heads/beta'
40-
run: echo "::set-env name=BETA::true"
40+
run: echo "BETA=true" >> $GITHUB_ENV
4141

4242
- name: Use scripts and templates from master branch
4343
run: |

.github/workflows/remark.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@ jobs:
1616
steps:
1717
# Setup
1818
- name: Checkout
19-
uses: actions/checkout@v2.0.0
19+
uses: actions/checkout@v2.3.3
2020

2121
- name: Setup Node.js
22-
uses: actions/setup-node@v1.1.0
22+
uses: actions/setup-node@v1.4.4
2323

2424
- name: Install remark
2525
run: npm install remark-cli remark-lint remark-lint-maximum-line-length remark-preset-lint-recommended

0 commit comments

Comments
 (0)