@@ -34,35 +34,24 @@ jobs:
3434 - name : Set up chart-testing
3535 uses : helm/chart-testing-action@v2.3.1
3636
37- - name : Get changed files in the docs folder
38- id : files-changed
39- uses : tj-actions/changed-files@v35
40- with :
41- files : |
42- charts/**
43-
44- # change detection in ct seems to not detect some changes. Using simple file modification for now.
45- # - name: Run chart-testing (list-changed)
46- # id: list-changed
47- # run: |
48- # changed=$(ct list-changed --chart-dirs . --target-branch ${{ github.event.repository.default_branch }})
49- # if [[ -n "$changed" ]]; then
50- # echo "chart-changed=true" >> $GITHUB_OUTPUT
51- # fi
52- # - name: Run chart-testing (lint changed)
53- # run: ct lint --chart-dirs . --target-branch ${{ github.event.repository.default_branch }}
37+ - name : List changed charts
38+ id : list-changed
39+ run : |
40+ ## If executed with debug this won't work anymore.
41+ changed=$(ct --config ./.github/configs/ct.yaml list-changed)
42+ charts=$(echo "$changed" | tr '\n' ' ' | xargs)
43+ if [[ -n "$changed" ]]; then
44+ echo "changed=true" >> $GITHUB_STATE
45+ echo "changed_charts=$charts" >> $GITHUB_STATE
46+ fi
5447
5548 - name : Run chart-testing (lint)
56- run : ct lint --all
49+ run : ct lint --debug --config ./.github/configs/ct.yaml --lint-conf ./.github/configs/lintconf.yaml
5750
5851 - name : Create kind cluster
5952 uses : helm/kind-action@v1.4.0
60- # if: steps.list-changed.outputs.chart-changed == 'true' || steps.files-changed.outputs.any_modified == 'true'
61- if : steps.files-changed.outputs.any_modified == 'true'
62-
63- # - name: Run chart-testing (install changed)
64- # run: ct install --chart-dirs . --target-branch ${{ github.event.repository.default_branch }} --upgrade
53+ if : steps.list-changed.outputs.changed == 'true'
6554
6655 - name : Run chart-testing (install)
67- run : ct install --all
68- if : steps.files -changed.outputs.any_modified == 'true'
56+ run : ct install --config ./.github/configs/ct.yaml
57+ if : steps.list -changed.outputs.changed == 'true'
0 commit comments