Skip to content

DUPLO-26211 TF:EKS: Add support for taints update #7527

DUPLO-26211 TF:EKS: Add support for taints update

DUPLO-26211 TF:EKS: Add support for taints update #7527

Workflow file for this run

name: Lint and Format
on:
pull_request:
push:
branches-ignore:
- master
- release/*
tags-ignore:
- v*
jobs:
lint:
runs-on: ubuntu-22.04
steps:
-
name: Checkout
uses: actions/checkout@v3
-
name: Set up Go
uses: actions/setup-go@v5
with:
go-version-file: 'go.mod'
cache: false
- name: Clean Go Build Cache
run: go clean -cache -modcache -testcache
-
name: Run linting
uses: golangci/[email protected]
with:
only-new-issues: true # Only show new issues for pull requests.
args: --timeout=5m
version: v1.60
format:
runs-on: ubuntu-22.04
steps:
-
name: Checkout
uses: actions/checkout@v3
-
name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '^1.20.0'
cache: false
-
name: Run formatting
run: gofmt -s -w duplocloud duplosdk
-
name: Check if formatting changed
id: git-check
run: |
if git diff-index --quiet HEAD --; then
echo "modified=false" >> $GITHUB_ENV;
else
echo "modified=true" >> $GITHUB_ENV;
fi
-
name: Commit formatting changes
if: env.modified == 'true'
run: |
git config --global user.name 'Duplo Githug Bot'
git config --global user.email '[email protected]'
git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}
git commit -am "lint: go fmt"
git push