Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/continuous-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
go-version-file: 'go.mod'

- name: Go Format
run: gofmt -s -w . && git diff --exit-code
run: make format

- name: Go Build
run: go build ./...
Expand All @@ -31,10 +31,10 @@ jobs:
uses: golangci/golangci-lint-action@v9

- name: Test
run: go test -v -count=1 -race -shuffle=on -coverprofile=coverage.txt -json ./... > test.json
run: make test

- name: Annotate tests
if: always()
uses: guyarb/golang-test-annotations@v0.8.0
with:
test-results: test.json
test-results: test.json
2 changes: 1 addition & 1 deletion .github/workflows/release-create.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
go-version-file: 'go.mod'

- name: Build binaries
run: go build ./cmd/osmanage
run: make build-prod

- name: Create release
uses: marvinpinto/action-automatic-releases@latest
Expand Down
18 changes: 18 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@

# Build

build-prod osmanage:
CGO_ENABLED=0 go build -a -ldflags="-s -w" -o osmanage ./cmd/osmanage

build-dev:
go build -o osmanage ./cmd/osmanage


# Tests / Linting

test:
go test -v -count=1 -race -shuffle=on -coverprofile=coverage.txt ./...

format:
gofmt -s -w . && git diff --exit-code

Loading
Loading