Repository navigation
57 lines (52 loc) · 1.86 KB
/
Copy pathzz_generated.pre-commit.yaml
File metadata and controls
57 lines (52 loc) · 1.86 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
# DO NOT EDIT. Generated with:
#
# devctl
#
# https://github.com/giantswarm/devctl/blob/18dd9b0d1c8c275c87f7b22511565f66d94b921a/pkg/gen/input/precommit/internal/file/pre-commit-action.yaml.template
#
name: pre-commit
on:
pull_request:
merge_group:
push:
branches:
- main
- master
permissions: {}
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
env:
HELM_DOCS_VERSION: "1.14.2"
jobs:
pre-commit:
runs-on: ubuntu-26.04
timeout-minutes: 30
permissions:
contents: read
steps:
- name: Check out code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- name: Set up Python environment
uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
- name: Install helm-docs
uses: giantswarm/install-binary-action@5bef88f65012037dd836117c8d344b21bb559854 # v4.1.0
with:
binary: helm-docs
version: "${{ env.HELM_DOCS_VERSION }}"
download_url: "https://github.com/norwoodj/helm-docs/releases/download/v${version}/helm-docs_${version}_Linux_x86_64.tar.gz"
tarball_binary_path: "helm-docs"
smoke_test: "${binary} --version"
- name: Install pre-commit
run: python -m pip install pre-commit
- name: List installed Python packages
run: python -m pip freeze --local
- name: Restore pre-commit cache
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: ~/.cache/pre-commit
key: pre-commit-3|${{ env.pythonLocation }}|${{ hashFiles('.pre-commit-config.yaml') }}
- name: Execute pre-commit hooks
run: pre-commit run --show-diff-on-failure --color=always --all-files
env:
GOGC: "20"