Skip to content

Merge upstream v2.4.2 (Go 1.26.2 + logrus CVE fixes) #15

Merge upstream v2.4.2 (Go 1.26.2 + logrus CVE fixes)

Merge upstream v2.4.2 (Go 1.26.2 + logrus CVE fixes) #15

Workflow file for this run

name: Code formatting
on:
pull_request:
branches: [ "main" ]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
format:
name: gofmt validation
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.ref }}
repository: ${{ github.event.pull_request.head.repo.full_name }}
- name: gofmt
run: |
unformatted=$(gofmt -s -l .)
if [ -n "$unformatted" ]; then
echo "Gofmt validation failed. The following files need formatting:"
echo "$unformatted"
echo ""
echo "Run 'gofmt -s -w .' locally and commit the result."
exit 1
fi