From 30450925ba463efc5f84b8f66d03c6e929e08fcb Mon Sep 17 00:00:00 2001 From: "zhipeng.hu" Date: Fri, 4 Aug 2023 10:08:13 +0800 Subject: [PATCH] dpr:8 --- .drone.yml | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/.drone.yml b/.drone.yml index 88a29f8..68d6a1c 100644 --- a/.drone.yml +++ b/.drone.yml @@ -9,18 +9,18 @@ volumes: path: /usr/local/path/gopath steps: -# - name: golang-build -# image: golang -# volumes: -# - name: gopath -# path: /go -# commands: -# - export GOPROXY=https://goproxy.cn -# - go mod init test-drone -# - go mod tidy -# - CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o test-drone -# when: -# target: [ "" ] + - name: golang-build + image: golang + volumes: + - name: gopath + path: /go + commands: + - export GOPROXY=https://goproxy.cn + - go mod init test-drone + - go mod tidy + - CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o test-drone + when: + target: [ "test","pre" ] # - name: docker-push # image: plugins/docker