diff --git a/.github/workflows/actionlint.yml b/.github/workflows/actionlint.yml deleted file mode 100644 index 68fc4d76c4..0000000000 --- a/.github/workflows/actionlint.yml +++ /dev/null @@ -1,15 +0,0 @@ -name: Lint GitHub Actions workflows -on: [push, pull_request] - -permissions: - contents: read - -jobs: - actionlint: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v5 - - name: Check workflow files - uses: docker://rhysd/actionlint:latest - with: - args: -color -ignore SC2086 diff --git a/.github/workflows/golangci-lint.yml b/.github/workflows/golangci-lint.yml deleted file mode 100644 index 4faf1c47be..0000000000 --- a/.github/workflows/golangci-lint.yml +++ /dev/null @@ -1,19 +0,0 @@ -name: golangci-lint -on: - merge_group: - pull_request: -permissions: - contents: read - checks: write - pull-requests: read -jobs: - golangci: - name: lint - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v5 - - name: golangci-lint - uses: golangci/golangci-lint-action@v8.0.0 - with: - version: v2.5.0 - args: --timeout 5m diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml new file mode 100644 index 0000000000..3a654a278e --- /dev/null +++ b/.github/workflows/lint.yml @@ -0,0 +1,84 @@ +name: Lint + +permissions: + contents: read + checks: write + pull-requests: read + +on: + pull_request: + merge_group: + +jobs: + terrafmt: + name: terrafmt + runs-on: ubuntu-latest + steps: + # Checkout should always be before setup-go to ensure caching is working + - uses: actions/checkout@v5 + - uses: actions/setup-go@v6 + with: + go-version: stable + - name: Run terrafmt on documentation + run: go tool terrafmt fmt --verbose --check ./docs + + spelling: + name: Spell Check with Typos + runs-on: ubuntu-latest + steps: + - name: Checkout Actions Repository + uses: actions/checkout@v4 + - name: Spell Check Repo + uses: crate-ci/typos@v1.39.0 + env: + CLICOLOR: 1 + + tfproviderlint: + name: tfproviderlint + runs-on: ubuntu-latest + steps: + # Checkout should always be before setup-go to ensure caching is working + - uses: actions/checkout@v5 + - uses: actions/setup-go@v6 + with: + go-version: stable + - name: Install tfproviderlint + run: go install github.com/bflad/tfproviderlint/cmd/tfproviderlint + - name: Run tfproviderlint + run: make tfproviderlint + - name: Run tfproviderlintx + run: make tfproviderlintx + + tfproviderdocs: + name: tfproviderdocs + runs-on: ubuntu-latest + steps: + # Checkout should always be before setup-go to ensure caching is working + - uses: actions/checkout@v5 + - uses: actions/setup-go@v6 + with: + go-version: stable + - uses: hashicorp/setup-terraform@v3 + - run: go install github.com/bflad/tfproviderdocs@latest + - run: make tfproviderdocs + + actionlint: + name: actionlint + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v5 + - name: Check workflow files + uses: docker://rhysd/actionlint:latest + with: + args: -color -ignore SC2086 + + golangci: + name: golangci-lint + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v5 + - name: golangci-lint + uses: golangci/golangci-lint-action@v8.0.0 + with: + version: v2.5.0 + args: --timeout 5m diff --git a/.github/workflows/spelling.yml b/.github/workflows/spelling.yml deleted file mode 100644 index 114e733ba1..0000000000 --- a/.github/workflows/spelling.yml +++ /dev/null @@ -1,19 +0,0 @@ -name: Spelling - -permissions: - contents: read - -on: [pull_request] - - -jobs: - spelling: - name: Spell Check with Typos - runs-on: ubuntu-latest - steps: - - name: Checkout Actions Repository - uses: actions/checkout@v4 - - name: Spell Check Repo - uses: crate-ci/typos@v1.39.0 - env: - CLICOLOR: 1 diff --git a/.github/workflows/terrafmt.yml b/.github/workflows/terrafmt.yml deleted file mode 100644 index 7ca97e905f..0000000000 --- a/.github/workflows/terrafmt.yml +++ /dev/null @@ -1,21 +0,0 @@ -name: Run terrafmt - -permissions: - contents: read - -on: - pull_request: - push: - merge_group: - -jobs: - terrafmt: - runs-on: ubuntu-latest - steps: - # Checkout should always be before setup-go to ensure caching is working - - uses: actions/checkout@v5 - - uses: actions/setup-go@v6 - with: - go-version: stable - - name: Run terrafmt on documentation - run: go tool terrafmt fmt --verbose --check ./docs diff --git a/.github/workflows/tfproviderlint.yml b/.github/workflows/tfproviderlint.yml deleted file mode 100644 index 4dc2cd90cd..0000000000 --- a/.github/workflows/tfproviderlint.yml +++ /dev/null @@ -1,36 +0,0 @@ -name: Run tfproviderlint - -permissions: - contents: read - -on: - pull_request: - push: - merge_group: - -jobs: - tfproviderlint: - runs-on: ubuntu-latest - steps: - # Checkout should always be before setup-go to ensure caching is working - - uses: actions/checkout@v5 - - uses: actions/setup-go@v6 - with: - go-version: stable - - name: Install tfproviderlint - run: go install github.com/bflad/tfproviderlint/cmd/tfproviderlint - - name: Run tfproviderlint - run: make tfproviderlint - - name: Run tfproviderlintx - run: make tfproviderlintx - tfproviderdocs: - runs-on: ubuntu-latest - steps: - # Checkout should always be before setup-go to ensure caching is working - - uses: actions/checkout@v5 - - uses: actions/setup-go@v6 - with: - go-version: stable - - uses: hashicorp/setup-terraform@v3 - - run: go install github.com/bflad/tfproviderdocs@latest - - run: make tfproviderdocs