fix(ansible): update community.docker ( 3.12.1 → 3.12.2 ) #14956
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json | |
name: pre-commit | |
on: | |
pull_request: | |
push: | |
branches: | |
- main | |
jobs: | |
pre-commit: | |
runs-on: ubuntu-latest | |
env: | |
yq-version: v4.25.2 | |
steps: | |
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 | |
with: | |
fetch-depth: 1 | |
- uses: actions/setup-python@f677139bbe7f9c59b41e40162b753c062f5d49a3 # v5 | |
with: | |
python-version: 3.x | |
- name: Cache yq | |
id: cache-yq | |
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4 | |
with: | |
path: bin/yq | |
key: yq-${{ env.yq-version }} | |
- name: Install yq | |
if: steps.cache-yq.outputs.cache-hit != 'true' | |
run: | | |
mkdir -p bin | |
wget https://github.com/mikefarah/yq/releases/download/${{ env.yq-version }}/yq_linux_amd64 -O bin/yq | |
chmod +x bin/yq | |
- name: Cache deduplicated pre-commit config | |
id: cache-precommitconfig | |
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4 | |
with: | |
path: .github/.pre-commit-config.yaml | |
key: precommitconfig-${{ hashFiles('.pre-commit-config.yaml') }} | |
- name: Remove duplicates from pre-commit config | |
if: steps.cache-precommitconfig.outputs.cache-hit != 'true' | |
run: | | |
bin/yq 'del(.repos.[].hooks[] | select(.id == "shellcheck" or .id == "yamllint" or .id == "kustomize" or .id == "gitleaks"))' .pre-commit-config.yaml > .github/.pre-commit-config.yaml | |
- uses: pre-commit/action@2c7b3805fd2a0fd8c1884dcaebf91fc102a13ecd # v3.0.1 | |
with: | |
extra_args: -c .github/.pre-commit-config.yaml |