Skip to content

Fixes formatting in main go #4

Fixes formatting in main go

Fixes formatting in main go #4

Workflow file for this run

name: Go Formatting
on:
pull_request:
push:
branches: [main]
paths:
- 'backend/aashub/**.go'
jobs:
gofmt:
name: GoFmt Check
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: '1.22.5'
- name: Run GoFmt
id: gofmt-run
run: |
gofmt -d backend/aashub/ > gofmt_output.txt
if [ -s gofmt_output.txt ]; then
echo "Formatting issues found:"
cat gofmt_output.txt
exit 1
fi
- name: GoFmt Output
if: failure()
run: echo "Check formatting issues in the logs."