From 54e6823bc06f5980cf6221e8891604f57688780f Mon Sep 17 00:00:00 2001 From: "Mikhail f. Shiryaev" Date: Fri, 24 Sep 2021 11:39:06 +0200 Subject: [PATCH 1/2] Use proper find for sources dependencies in Makefile --- Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 3fd0ded7..ac6dca24 100644 --- a/Makefile +++ b/Makefile @@ -15,6 +15,8 @@ else VERSION:=$(shell sh -c 'git describe --always --tags | sed -e "s/^v//i"') endif +SRCS:=$(shell find . -name '*.go') + all: $(NAME) .PHONY: clean @@ -24,7 +26,7 @@ clean: rm -f *deb *rpm rm -f sha256sum md5sum -$(NAME): $(shell find . -name '*.go') +$(NAME): $(SRCS) $(GO) build $(MODULE) e2e-test: $(NAME) From babf6b4790b8c4d903e6cf58777f53c1f94ee4a2 Mon Sep 17 00:00:00 2001 From: "Mikhail f. Shiryaev" Date: Fri, 24 Sep 2021 12:23:20 +0200 Subject: [PATCH 2/2] Compile static binaries, update go matrix --- .github/workflows/release.yml | 6 ++++++ .github/workflows/tests.yml | 6 +++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 404fb611..8415bdc8 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -11,6 +11,7 @@ jobs: runs-on: ubuntu-latest env: BINARY: ${{ github.event.repository.name }} + CGO_ENABLED: 0 outputs: matrix: ${{ steps.build.outputs.matrix }} @@ -23,6 +24,11 @@ jobs: - uses: actions/checkout@v2 name: Checkout + - name: Test + run: make test + env: + CGO_ENABLED: 1 + - name: Set up Ruby uses: ruby/setup-ruby@v1 with: diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 0115f19c..ed20edd5 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -9,14 +9,16 @@ on: jobs: tests: + env: + CGO_ENABLED: 0 name: Test code runs-on: ubuntu-latest strategy: matrix: go: - - ^1.14 - ^1.15 - ^1.16 + - ^1.17 - ^1 steps: @@ -43,6 +45,8 @@ jobs: - name: Test run: make test + env: + CGO_ENABLED: 1 - name: Set up Ruby uses: ruby/setup-ruby@v1