Skip to content

Commit

Permalink
Add github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
slavovojacek committed May 25, 2024
1 parent 512bac1 commit 7358e1e
Showing 1 changed file with 45 additions and 0 deletions.
45 changes: 45 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: CI

on: [push, pull_request]

jobs:
gofmt:
name: Go Format
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.22'
- name: Run gofmt
run: gofmt -l -s .

# golangci-lint:
# name: Go Lint
# runs-on: ubuntu-latest
# steps:
# - name: Checkout code
# uses: actions/checkout@v4
# - name: Set up Go
# uses: actions/setup-go@v5
# with:
# go-version: '1.22'
# - name: Install golangci-lint
# run: go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest
# - name: Run golangci-lint
# run: golangci-lint run

test:
name: Go Test
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.22'
- name: Run tests
run: go test ./... -v

0 comments on commit 7358e1e

Please sign in to comment.