ignore version in helm doc diff check #124
Workflow file for this run
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
name: Code | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
go: | |
name: Go Tests | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out code into the Go module directory | |
uses: actions/checkout@v4 | |
- name: Set up Go | |
uses: actions/setup-go@v5 | |
with: | |
go-version-file: "go.mod" | |
- name: Test | |
run: make test-cover | |
- name: Send coverage | |
uses: shogo82148/actions-goveralls@v1 | |
with: | |
path-to-profile: coverprofile.out | |
lint: | |
name: Go Lint | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out code into the Go module directory | |
uses: actions/checkout@v4 | |
- name: Set up Go | |
uses: actions/setup-go@v5 | |
with: | |
go-version-file: "go.mod" | |
- name: golangci-lint | |
uses: golangci/golangci-lint-action@v6 | |
with: | |
skip-cache: true | |
helm: | |
name: Helm Checks | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out code into the Go module directory | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Install Helm | |
run: | | |
curl https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3 | bash | |
- name: Set up Go | |
uses: actions/setup-go@v5 | |
with: | |
go-version-file: "go.mod" | |
- name: Set up Tools | |
run: make tb.semver tb.helm-docs | |
- name: Lint | |
run: | | |
cp chart/README.md chart/README.md.old | |
make helm-lint | |
- name: Check chart/README.md is correctly generated with 'make docs' | |
run: | | |
# ignore version as it is updated during build | |
sed -i '/!\[Version\:/d' chart/README.md | |
sed -i '/!\[Version\:/d' chart/README.md.old | |
sed -i -E 's/--version [0-9]+.[0-9]+.[0-9]+/--version x.x.x/' chart/README.md | |
sed -i -E 's/--version [0-9]+.[0-9]+.[0-9]+/--version x.x.x/' chart/README.md.old | |
diff chart/README.md.old chart/README.md | |
- name: Set up chart-testing | |
uses: helm/chart-testing-action@v2.6.1 | |
- name: Run chart-testing (lint) | |
run: ct lint --config .github/linters/ct.yaml | |
- name: Template | |
run: make helm-template |