Skip to content

Commit e998365

Browse files
committed
workflows: update checkout actions
Remove fetch-depth from checkout actions, since that was required by Nerdbank.GitVersioning. Also take this opportunity to use consistent version and naming for checkout actions.
1 parent be0a124 commit e998365

File tree

5 files changed

+22
-47
lines changed

5 files changed

+22
-47
lines changed

.github/workflows/codeql-analysis.yml

+1-4
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,7 @@ jobs:
2222
language: [ 'csharp' ]
2323

2424
steps:
25-
- name: Checkout repository
26-
uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
27-
with:
28-
fetch-depth: 0 # patch around Nerdbank.GitVersioning failure
25+
- uses: actions/checkout@v3
2926

3027
# Initializes the CodeQL tools for scanning.
3128
- name: Initialize CodeQL

.github/workflows/continuous-integration.yml

+1-3
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,7 @@ jobs:
1717
os: [ubuntu-latest, windows-latest, macos-latest]
1818

1919
steps:
20-
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
21-
with:
22-
fetch-depth: 0 # Indicate full history so Nerdbank.GitVersioning works.
20+
- uses: actions/checkout@v3
2321

2422
- name: Setup .NET
2523
uses: actions/[email protected]

.github/workflows/lint-docs.yml

+4-2
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@ jobs:
1818
name: Lint markdown files
1919
runs-on: ubuntu-latest
2020
steps:
21-
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
21+
- name: Check out repository
22+
uses: actions/checkout@v3
2223

2324
- uses: DavidAnson/markdownlint-cli2-action@5b7c9f74fec47e6b15667b2cc23c63dff11e449e
2425
with:
@@ -30,7 +31,8 @@ jobs:
3031
name: Check for broken links
3132
runs-on: ubuntu-latest
3233
steps:
33-
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
34+
- name: Check out repository
35+
uses: actions/checkout@v3
3436

3537
- name: Run link checker
3638
# For any troubleshooting, see:

.github/workflows/release.yml

+11-33
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,7 @@ jobs:
1414
matrix:
1515
runtime: [ osx-x64, osx-arm64 ]
1616
steps:
17-
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
18-
with:
19-
fetch-depth: 0 # Indicate full history so Nerdbank.GitVersioning works.
17+
- uses: actions/checkout@v3
2018

2119
- name: Set up dotnet
2220
uses: actions/[email protected]
@@ -77,8 +75,7 @@ jobs:
7775
runtime: [ osx-x64, osx-arm64 ]
7876
needs: osx-build
7977
steps:
80-
- name: Check out repository
81-
uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
78+
- uses: actions/checkout@v3
8279

8380
- name: Download payload
8481
uses: actions/download-artifact@v3
@@ -137,10 +134,7 @@ jobs:
137134
runtime: [ osx-x64, osx-arm64 ]
138135
needs: osx-payload-sign
139136
steps:
140-
- name: Check out repository
141-
uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
142-
with:
143-
fetch-depth: 0 # Indicate full history so Nerdbank.GitVersioning works.
137+
- uses: actions/checkout@v3
144138

145139
- name: Set version environment variable
146140
run: echo "VERSION=$(cat VERSION)" >> $GITHUB_ENV
@@ -188,8 +182,7 @@ jobs:
188182
runtime: [ osx-x64, osx-arm64 ]
189183
needs: osx-pack
190184
steps:
191-
- name: Check out repository
192-
uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
185+
- uses: actions/checkout@v3
193186

194187
- name: Download unsigned package
195188
uses: actions/download-artifact@v3
@@ -255,9 +248,7 @@ jobs:
255248
name: Build and Sign Windows
256249
runs-on: windows-latest
257250
steps:
258-
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
259-
with:
260-
fetch-depth: 0 # Indicate full history so Nerdbank.GitVersioning works.
251+
- uses: actions/checkout@v3
261252

262253
- name: Set up dotnet
263254
uses: actions/[email protected]
@@ -363,9 +354,7 @@ jobs:
363354
name: Build Linux
364355
runs-on: ubuntu-latest
365356
steps:
366-
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
367-
with:
368-
fetch-depth: 0 # Indicate full history so Nerdbank.GitVersioning works.
357+
- uses: actions/checkout@v3
369358

370359
- name: Setup .NET
371360
uses: actions/[email protected]
@@ -397,7 +386,7 @@ jobs:
397386
# ESRP service requires signing to run on Windows
398387
runs-on: windows-latest
399388
steps:
400-
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
389+
- uses: actions/checkout@v3
401390

402391
- name: Download artifacts
403392
uses: actions/download-artifact@v3
@@ -452,8 +441,6 @@ jobs:
452441
runs-on: ubuntu-latest
453442
steps:
454443
- uses: actions/checkout@v3
455-
with:
456-
fetch-depth: 0 # Indicate full history so Nerdbank.GitVersioning works.
457444

458445
- name: Setup .NET
459446
uses: actions/[email protected]
@@ -481,8 +468,7 @@ jobs:
481468
runs-on: windows-latest
482469
needs: dotnet-tool-build
483470
steps:
484-
- name: Check out repository
485-
uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
471+
- uses: actions/checkout@v3
486472

487473
- name: Download payload
488474
uses: actions/download-artifact@v3
@@ -545,8 +531,6 @@ jobs:
545531
run: echo "VERSION=$(cat VERSION)" >> $GITHUB_ENV
546532

547533
- uses: actions/checkout@v3
548-
with:
549-
fetch-depth: 0 # Indicate full history so Nerdbank.GitVersioning works.
550534

551535
- name: Download signed payload
552536
uses: actions/download-artifact@v3
@@ -581,8 +565,7 @@ jobs:
581565
runs-on: windows-latest
582566
needs: dotnet-tool-pack
583567
steps:
584-
- name: Check out repository
585-
uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
568+
- uses: actions/checkout@v3
586569

587570
- name: Download unsigned package
588571
uses: actions/download-artifact@v3
@@ -666,9 +649,7 @@ jobs:
666649
runs-on: ${{ matrix.component.os }}
667650
needs: [ osx-sign, win-sign, linux-sign, dotnet-tool-sign ]
668651
steps:
669-
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
670-
with:
671-
fetch-depth: 0 # Indicate full history so Nerdbank.GitVersioning works.
652+
- uses: actions/checkout@v3
672653

673654
- name: Set version environment variable
674655
run: echo "VERSION=$(cat VERSION)" >> $GITHUB_ENV
@@ -736,10 +717,7 @@ jobs:
736717
runs-on: ubuntu-latest
737718
needs: [ validate ]
738719
steps:
739-
- name: Check out repository
740-
uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
741-
with:
742-
fetch-depth: 0 # Indicate full history so Nerdbank.GitVersioning works.
720+
- uses: actions/checkout@v3
743721

744722
- name: Set version environment variable
745723
run: echo "VERSION=$(cat VERSION)" >> $GITHUB_ENV

.github/workflows/validate-install-from-source.yml

+5-5
Original file line numberDiff line numberDiff line change
@@ -34,10 +34,10 @@ jobs:
3434
zypper -n install tar gzip
3535
elif [[ ${{matrix.vector.image}} == *"centos"* ]]; then
3636
dnf install which -y
37-
fi
38-
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
39-
with:
40-
fetch-depth: 0 # Indicate full history so Nerdbank.GitVersioning works.
37+
fi
38+
39+
- uses: actions/checkout@v3
40+
4141
- run: |
4242
sh "${GITHUB_WORKSPACE}/src/linux/Packaging.Linux/install-from-source.sh" -y
43-
git-credential-manager --help || exit 1
43+
git-credential-manager --help || exit 1

0 commit comments

Comments
 (0)