github.com/siglens/siglens@v0.0.0-20240328180423-f7ce9ae441ed/Makefile (about)

     1  
     2  
     3  GO := $(shell which go)
     4  ifeq ($(GO), )
     5  	GO := /usr/local/go/bin/go
     6  endif
     7  export GO 
     8  
     9  
    10  lint:
    11  	golangci-lint run --timeout=3m
    12  
    13  test:
    14  	$(GO) test ./... -count 1
    15  
    16  build:
    17  	$(GO) mod tidy
    18  	$(GO) build -o siglens cmd/siglens/main.go
    19  
    20  run:
    21  	$(GO) run cmd/siglens/main.go --config server.yaml
    22  
    23  gofmt :
    24  	$(GO) install golang.org/x/tools/cmd/goimports@latest
    25  	~/go/bin/goimports -w .
    26  
    27  all: lint test build
    28  
    29  pr: all gofmt