good morning!!!!

Skip to content
Snippets Groups Projects
Unverified Commit 246891f1 authored by Mathias Fredriksson's avatar Mathias Fredriksson Committed by GitHub
Browse files

build: add Makefile (#525)

parent 778d161b
Branches
No related tags found
No related merge requests found
......@@ -18,7 +18,7 @@ jobs:
- uses: actions/setup-go@v5
with:
go-version-file: ./go.mod
- run: ./ci/fmt.sh
- run: make fmt
lint:
runs-on: ubuntu-latest
......@@ -28,7 +28,7 @@ jobs:
- uses: actions/setup-go@v5
with:
go-version-file: ./go.mod
- run: ./ci/lint.sh
- run: make lint
test:
runs-on: ubuntu-latest
......@@ -43,7 +43,7 @@ jobs:
- uses: actions/setup-go@v5
with:
go-version-file: ./go.mod
- run: ./ci/test.sh
- run: make test
- uses: actions/upload-artifact@v4
with:
name: coverage.html
......@@ -56,4 +56,4 @@ jobs:
- uses: actions/setup-go@v5
with:
go-version-file: ./go.mod
- run: ./ci/bench.sh
- run: make bench
......@@ -15,7 +15,7 @@ jobs:
- uses: actions/setup-go@v5
with:
go-version-file: ./go.mod
- run: AUTOBAHN=1 ./ci/bench.sh
- run: AUTOBAHN=1 make bench
test:
runs-on: ubuntu-latest
steps:
......@@ -29,7 +29,7 @@ jobs:
- uses: actions/setup-go@v5
with:
go-version-file: ./go.mod
- run: AUTOBAHN=1 ./ci/test.sh
- run: AUTOBAHN=1 make test
- uses: actions/upload-artifact@v4
with:
name: coverage.html
......@@ -43,7 +43,7 @@ jobs:
- uses: actions/setup-go@v5
with:
go-version-file: ./go.mod
- run: AUTOBAHN=1 ./ci/bench.sh
- run: AUTOBAHN=1 make bench
test-dev:
runs-on: ubuntu-latest
steps:
......@@ -59,7 +59,7 @@ jobs:
- uses: actions/setup-go@v5
with:
go-version-file: ./go.mod
- run: AUTOBAHN=1 ./ci/test.sh
- run: AUTOBAHN=1 make test
- uses: actions/upload-artifact@v4
with:
name: coverage-dev.html
......
......@@ -38,7 +38,7 @@ jobs:
go-version-file: ./go.mod
- name: Generate coverage and badge
run: |
./ci/test.sh
make test
mkdir -p ./ci/out/static
cp ./ci/out/coverage.html ./ci/out/static/coverage.html
percent=$(go tool cover -func ./ci/out/coverage.prof | tail -n1 | awk '{print $3}' | tr -d '%')
......
Makefile 0 → 100644
.PHONY: all
all: fmt lint test
.PHONY: fmt
fmt:
./ci/fmt.sh
.PHONY: lint
lint:
./ci/lint.sh
.PHONY: test
test:
./ci/test.sh
.PHONY: bench
bench:
./ci/bench.sh
\ No newline at end of file
#!/bin/sh
set -x
set -eu
cd -- "$(dirname "$0")/.."
......
#!/bin/sh
set -eu
cd -- "$(dirname "$0")"
echo "=== fmt.sh"
./ci/fmt.sh
echo "=== lint.sh"
./ci/lint.sh
echo "=== test.sh"
./ci/test.sh "$@"
echo "=== bench.sh"
./ci/bench.sh
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment