@@ -114,7 +114,7 @@ jobs:
114
114
submodules : true
115
115
- name : Run documentation check
116
116
run : |
117
- apt-get -qq update && apt-get -qq -y install curl yq
117
+ which curl yq || ( apt -q update && apt -yq install curl yq)
118
118
curl -s https://raw.githubusercontent.com/swiftlang/github-workflows/refs/heads/main/.github/workflows/scripts/check-docs.sh | bash
119
119
120
120
unacceptable-language-check :
@@ -181,7 +181,7 @@ jobs:
181
181
run : git config --global --add safe.directory ${GITHUB_WORKSPACE}
182
182
- name : Run format check
183
183
run : |
184
- apt-get -qq update && apt-get -qq -y install curl
184
+ which curl || ( apt -q update && apt -yq install curl)
185
185
curl -s https://raw.githubusercontent.com/swiftlang/github-workflows/refs/heads/main/.github/workflows/scripts/check-swift-format.sh | bash
186
186
187
187
shell-check :
@@ -202,7 +202,7 @@ jobs:
202
202
run : git config --global --add safe.directory ${GITHUB_WORKSPACE}
203
203
- name : Run shellcheck
204
204
run : |
205
- apt-get -qq update && apt-get -qq -y install shellcheck
205
+ which shellcheck || ( apt -q update && apt -yq install shellcheck)
206
206
git ls-files -z '*.sh' | xargs -0 --no-run-if-empty shellcheck
207
207
208
208
yaml-lint-check :
@@ -218,7 +218,7 @@ jobs:
218
218
submodules : true
219
219
- name : Run yamllint
220
220
run : |
221
- which yamllint >/dev/null || ( apt-get update && apt-get install -y yamllint )
221
+ which yamllint || (apt -q update && apt install -yq yamllint)
222
222
cd ${GITHUB_WORKSPACE}
223
223
if [ ! -f ".yamllint.yml" ]; then
224
224
echo "Downloading default yamllint config file"
0 commit comments