mirror of
https://codeberg.org/cunicu/cunicu.git
synced 2025-09-27 05:06:02 +08:00
fix(build): Define linting flags in one place
Signed-off-by: Steffen Vogel <post@steffenvogel.de>
This commit is contained in:
2
.github/workflows/build.yaml
vendored
2
.github/workflows/build.yaml
vendored
@@ -146,7 +146,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Lint
|
- name: Lint
|
||||||
if: ${{ matrix.host_os != 'windows' }}
|
if: ${{ matrix.host_os != 'windows' }}
|
||||||
run: make lint LINT_OPTS=--timeout=15m
|
run: make lint
|
||||||
|
|
||||||
- name: Run tests
|
- name: Run tests
|
||||||
if: ${{ matrix.target_arch == matrix.host_arch && matrix.target_os == matrix.host_os && matrix.host_os != 'windows' }}
|
if: ${{ matrix.target_arch == matrix.host_arch && matrix.target_os == matrix.host_os && matrix.host_os != 'windows' }}
|
||||||
|
@@ -10,7 +10,7 @@ project_name: cunicu
|
|||||||
|
|
||||||
before:
|
before:
|
||||||
hooks:
|
hooks:
|
||||||
- make prepare LINT_OPTS=--timeout=15m
|
- make prepare
|
||||||
|
|
||||||
checksum:
|
checksum:
|
||||||
name_template: "checksums.txt"
|
name_template: "checksums.txt"
|
||||||
|
2
Makefile
2
Makefile
@@ -5,6 +5,8 @@ PKG = $(shell grep module go.mod | cut -f2 -d" ")
|
|||||||
|
|
||||||
export CGO_ENABLED = 0
|
export CGO_ENABLED = 0
|
||||||
|
|
||||||
|
LINT_OPTS ?= --timeout=15m
|
||||||
|
|
||||||
LDFLAGS = -X cunicu.li/cunicu/pkg/buildinfo.Version=$(shell git describe --tags --dirty || echo unknown) \
|
LDFLAGS = -X cunicu.li/cunicu/pkg/buildinfo.Version=$(shell git describe --tags --dirty || echo unknown) \
|
||||||
-X cunicu.li/cunicu/pkg/buildinfo.Tag=$(shell git describe --tags) \
|
-X cunicu.li/cunicu/pkg/buildinfo.Tag=$(shell git describe --tags) \
|
||||||
-X cunicu.li/cunicu/pkg/buildinfo.Commit=$(shell git rev-parse HEAD) \
|
-X cunicu.li/cunicu/pkg/buildinfo.Commit=$(shell git rev-parse HEAD) \
|
||||||
|
Reference in New Issue
Block a user