forked from Project-HAMi/ascend-device-plugin
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
27 lines (20 loc) · 616 Bytes
/
Makefile
File metadata and controls
27 lines (20 loc) · 616 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
GO ?= go
VERSION ?= unknown
BUILDARGS ?= -ldflags '-s -w -X github.com/Project-HAMi/ascend-device-plugin/version.version=$(VERSION)'
IMG_NAME = projecthami/ascend-device-plugin
all: ascend-device-plugin
tidy:
$(GO) mod tidy
docker:
docker build \
--build-arg BASE_IMAGE=ubuntu:20.04 \
--build-arg GOPROXY=https://goproxy.cn,direct \
-t ${IMG_NAME}:${VERSION} .
lint:
$(GO) install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.61.0
golangci-lint run
ascend-device-plugin:
$(GO) build $(BUILDARGS) -o ./ascend-device-plugin ./cmd/main.go
clean:
rm -rf ./ascend-device-plugin
.PHONY: all clean