-
-
Notifications
You must be signed in to change notification settings - Fork 24
63 lines (59 loc) · 1.74 KB
/
prepare.yml
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
58
59
60
61
62
63
name: Chart-Preparation
on:
pull_request:
branches: [main]
paths: ["charts/**"]
push:
branches: [main]
paths: ["charts/**"]
workflow_dispatch:
jobs:
pre-commit:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
- uses: pre-commit/[email protected]
documentation:
needs:
- pre-commit
runs-on: ubuntu-latest
container: ghcr.io/chgl/kube-powertools:latest
steps:
- name: checkout git repository
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: check which git version is installed
run: git version
- name: list contents
run: ls -al && pwd
- name: Generate documentation
run: generate-docs.sh
- name: Check if documentation is up-to-date
run: cd / && git diff --exit-code HEAD
- name: Check readme
shell: bash
run: |
set -euo pipefail
docker run --rm --volume "$(pwd):/helm-docs" -u "$(id -u)" jnorwood/helm-docs:latest
if ! git diff --exit-code
then
echo "Documentation not up to date. Please run helm-docs and commit changes!" >&2
exit 1
fi
changelog:
needs:
- pre-commit
runs-on: ubuntu-latest
container: ghcr.io/chgl/kube-powertools:latest
steps:
- name: checkout git repository
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Update dependencies
run: find charts/ ! -path charts/ -maxdepth 1 -type d -exec helm dependency update {} \;
# used to test whether the changelog generation process works properly
- name: Generate changelogs
run: bash .github/generate-chart-changelogs.sh