mirror of
https://github.com/spf13/cobra
synced 2025-05-06 05:17:21 +00:00
Merge branch 'master' of github.com:spf13/cobra into custom-help-verb
This commit is contained in:
commit
20a9b1acef
2 changed files with 50 additions and 34 deletions
|
@ -1,3 +1,49 @@
|
|||
version: 2
|
||||
|
||||
references:
|
||||
workspace: &workspace
|
||||
/go/src/github.com/spf13/cobra
|
||||
|
||||
run_tests: &run_tests
|
||||
run:
|
||||
name: "All Commands"
|
||||
command: |
|
||||
mkdir -p bin
|
||||
curl -Lso bin/shellcheck https://github.com/caarlos0/shellcheck-docker/releases/download/v0.4.6/shellcheck
|
||||
chmod +x bin/shellcheck
|
||||
go get -t -v ./...
|
||||
PATH=$PATH:$PWD/bin go test -v ./...
|
||||
go build
|
||||
if [ -z $NOVET ]; then
|
||||
diff -u <(echo -n) <(go tool vet . 2>&1 | grep -vE 'ExampleCommand|bash_completions.*Fprint');
|
||||
fi
|
||||
|
||||
jobs:
|
||||
go-current:
|
||||
docker:
|
||||
- image: circleci/golang:1.11
|
||||
working_directory: *workspace
|
||||
steps:
|
||||
- checkout
|
||||
- *run_tests
|
||||
- run:
|
||||
name: "Check formatting"
|
||||
command: diff -u <(echo -n) <(gofmt -d -s .)
|
||||
go-previous:
|
||||
docker:
|
||||
- image: circleci/golang:1.10
|
||||
working_directory: *workspace
|
||||
steps:
|
||||
- checkout
|
||||
- *run_tests
|
||||
go-latest:
|
||||
docker:
|
||||
- image: circleci/golang:latest
|
||||
working_directory: *workspace
|
||||
steps:
|
||||
- checkout
|
||||
- *run_tests
|
||||
|
||||
workflows:
|
||||
version: 2
|
||||
main:
|
||||
|
@ -5,34 +51,3 @@ workflows:
|
|||
- go-current
|
||||
- go-previous
|
||||
- go-latest
|
||||
base: &base
|
||||
working_directory: /go/src/github.com/spf13/cobra
|
||||
steps:
|
||||
- checkout
|
||||
- run:
|
||||
name: "All Commands"
|
||||
command: |
|
||||
mkdir -p bin
|
||||
curl -Lso bin/shellcheck https://github.com/caarlos0/shellcheck-docker/releases/download/v0.4.6/shellcheck
|
||||
chmod +x bin/shellcheck
|
||||
go get -t -v ./...
|
||||
PATH=$PATH:$PWD/bin go test -v ./...
|
||||
go build
|
||||
diff -u <(echo -n) <(gofmt -d -s .)
|
||||
if [ -z $NOVET ]; then
|
||||
diff -u <(echo -n) <(go tool vet . 2>&1 | grep -vE 'ExampleCommand|bash_completions.*Fprint');
|
||||
fi
|
||||
version: 2
|
||||
jobs:
|
||||
go-current:
|
||||
docker:
|
||||
- image: circleci/golang:1.10.0
|
||||
<<: *base
|
||||
go-previous:
|
||||
docker:
|
||||
- image: circleci/golang:1.9.4
|
||||
<<: *base
|
||||
go-latest:
|
||||
docker:
|
||||
- image: circleci/golang:latest
|
||||
<<: *base
|
||||
|
|
|
@ -2,9 +2,11 @@ language: go
|
|||
|
||||
matrix:
|
||||
include:
|
||||
- go: 1.9.4
|
||||
- go: 1.10.0
|
||||
- go: 1.10.x
|
||||
- go: 1.11.x
|
||||
- go: tip
|
||||
- go: 1.11.x
|
||||
script: diff -u <(echo -n) <(gofmt -d -s .)
|
||||
allow_failures:
|
||||
- go: tip
|
||||
|
||||
|
@ -15,7 +17,6 @@ before_install:
|
|||
script:
|
||||
- PATH=$PATH:$PWD/bin go test -v ./...
|
||||
- go build
|
||||
- diff -u <(echo -n) <(gofmt -d -s .)
|
||||
- if [ -z $NOVET ]; then
|
||||
diff -u <(echo -n) <(go tool vet . 2>&1 | grep -vE 'ExampleCommand|bash_completions.*Fprint');
|
||||
fi
|
||||
|
|
Loading…
Add table
Reference in a new issue