File tree Expand file tree Collapse file tree 1 file changed +42
-0
lines changed Expand file tree Collapse file tree 1 file changed +42
-0
lines changed Original file line number Diff line number Diff line change 1+ name : " Documentation Updates"
2+
3+ on :
4+ pull_request :
5+ paths :
6+ - ' docs/**'
7+ types : [opened, synchronize, labeled]
8+
9+ push :
10+ branches :
11+ - main
12+
13+ jobs :
14+ check-docs :
15+ runs-on : ubuntu-latest
16+
17+ if : ${{ !contains(github.event.pull_request.labels.*.name, 'no-documentation') }}
18+
19+ steps :
20+ - name : Checkout repository
21+ uses : actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4
22+
23+ - name : Set up Go
24+ uses : actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5.0.0
25+ with :
26+ go-version-file : ' go.mod'
27+
28+ - name : Install tfplugindocs command
29+ run : go install github.com/hashicorp/terraform-plugin-docs/cmd/tfplugindocs@latest
30+
31+ - name : Run tfplugindocs command
32+ run : tfplugindocs generate
33+
34+ - name : Check for changes
35+ run : |
36+ git diff --exit-code
37+
38+ - name : Undocumented changes
39+ run : |
40+ echo "Documentation is not up to date. Please refer to the `Making Changes` in the Contribution Guide on how to properly update documentation."
41+ exit 1
42+ if : failure()
You can’t perform that action at this time.
0 commit comments