diff --git a/.drone.yml b/.drone.yml index 88ab748..95c5c4d 100644 --- a/.drone.yml +++ b/.drone.yml @@ -18,6 +18,17 @@ steps: - name: gopath path: /go +- name: lint + pull: always + image: golang:1.12 + commands: + - make lint + environment: + GO111MODULE: on + volumes: + - name: gopath + path: /go + - name: misspell pull: always image: golang:1.12 diff --git a/README.md b/README.md index 148ae2a..1db3434 100644 --- a/README.md +++ b/README.md @@ -36,7 +36,7 @@ Copy files and artifacts via SSH using a binary, docker or [Drone CI](http://doc The pre-compiled binaries can be downloaded from [release page](https://github.com/appleboy/drone-scp/releases). Support the following OS type. * Windows amd64/386 -* Linux amd64/386 +* Linux arm/amd64/386 * Darwin amd64/386 With `Go` installed @@ -48,7 +48,14 @@ $ go get -u -v github.com/appleboy/drone-scp or build the binary with the following command: ``` -$ make build +$ export GOOS=linux +$ export GOARCH=amd64 +$ export CGO_ENABLED=0 +$ export GO111MODULE=on + +$ go test -cover ./... + +$ go build -v -a -tags netgo -o release/linux/amd64/drone-scp . ``` ## Docker diff --git a/pipeline.libsonnet b/pipeline.libsonnet index 27d009f..4fb6047 100644 --- a/pipeline.libsonnet +++ b/pipeline.libsonnet @@ -24,23 +24,23 @@ }, ], }, - // { - // name: 'lint', - // image: 'golang:1.12', - // pull: 'always', - // environment: { - // GO111MODULE: 'on', - // }, - // commands: [ - // 'make lint', - // ], - // volumes: [ - // { - // name: 'gopath', - // path: '/go', - // }, - // ], - // }, + { + name: 'lint', + image: 'golang:1.12', + pull: 'always', + environment: { + GO111MODULE: 'on', + }, + commands: [ + 'make lint', + ], + volumes: [ + { + name: 'gopath', + path: '/go', + }, + ], + }, { name: 'misspell', image: 'golang:1.12',