From f74e04527319c47fd61f23ef839f6fd7ff6af45e Mon Sep 17 00:00:00 2001 From: Julian Kornberger Date: Sun, 13 May 2018 20:59:54 +0200 Subject: [PATCH] Add Go Dep https://github.com/golang/dep --- .gitignore | 1 + .travis.yml | 3 +- Gopkg.lock | 88 +++++++++++++++++++++++++++++++++++++++++++++++++++++ Gopkg.toml | 58 +++++++++++++++++++++++++++++++++++ circle.yml | 9 ++++-- 5 files changed, 155 insertions(+), 4 deletions(-) create mode 100644 Gopkg.lock create mode 100644 Gopkg.toml diff --git a/.gitignore b/.gitignore index d7fdc53..894526c 100644 --- a/.gitignore +++ b/.gitignore @@ -24,3 +24,4 @@ _testmain.go *.prof webroot /config.toml +/vendor diff --git a/.travis.yml b/.travis.yml index c5fff3e..2fd6112 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,7 +3,8 @@ go: - 1.9.x - 1.10.x install: - - go get -t github.com/FreifunkBremen/yanic/... + - curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh + - dep ensure - go get github.com/client9/misspell/cmd/misspell - go get github.com/mattn/goveralls - go get golang.org/x/tools/cmd/cover diff --git a/Gopkg.lock b/Gopkg.lock new file mode 100644 index 0000000..1cd397f --- /dev/null +++ b/Gopkg.lock @@ -0,0 +1,88 @@ +# This file is autogenerated, do not edit; changes may be undone by the next 'dep ensure'. + + +[[projects]] + name = "github.com/NYTimes/gziphandler" + packages = ["."] + revision = "2600fb119af974220d3916a5916d6e31176aac1b" + version = "v1.0.1" + +[[projects]] + name = "github.com/davecgh/go-spew" + packages = ["spew"] + revision = "346938d642f2ec3594ed81d874461961cd0faa76" + version = "v1.1.0" + +[[projects]] + name = "github.com/fgrosse/graphigo" + packages = ["."] + revision = "55a0a92a703041a55ad5ee2c2647f9577a87fdc1" + version = "v2" + +[[projects]] + name = "github.com/inconshreveable/mousetrap" + packages = ["."] + revision = "76626ae9c91c4f2a10f34cad8ce83ea42c93bb75" + version = "v1.0" + +[[projects]] + name = "github.com/influxdata/influxdb" + packages = [ + "client/v2", + "models", + "pkg/escape" + ] + revision = "02d7d4f043b34ecb4e9b2dbec298c6f9450c2a32" + version = "v1.5.2" + +[[projects]] + name = "github.com/naoina/go-stringutil" + packages = ["."] + revision = "6b638e95a32d0c1131db0e7fe83775cbea4a0d0b" + version = "v0.1.0" + +[[projects]] + name = "github.com/naoina/toml" + packages = [ + ".", + "ast" + ] + revision = "e6f5723bf2a66af014955e0888881314cf294129" + version = "v0.1.1" + +[[projects]] + name = "github.com/pkg/errors" + packages = ["."] + revision = "645ef00459ed84a119197bfb8d8205042c6df63d" + version = "v0.8.0" + +[[projects]] + name = "github.com/pmezard/go-difflib" + packages = ["difflib"] + revision = "792786c7400a136282c1664665ae0a8db921c6c2" + version = "v1.0.0" + +[[projects]] + name = "github.com/spf13/cobra" + packages = ["."] + revision = "a1f051bc3eba734da4772d60e2d677f47cf93ef4" + version = "v0.0.2" + +[[projects]] + name = "github.com/spf13/pflag" + packages = ["."] + revision = "583c0c0531f06d5278b7d917446061adc344b5cd" + version = "v1.0.1" + +[[projects]] + name = "github.com/stretchr/testify" + packages = ["assert"] + revision = "12b6f73e6084dad08a7c6e575284b177ecafbc71" + version = "v1.2.1" + +[solve-meta] + analyzer-name = "dep" + analyzer-version = 1 + inputs-digest = "fdc5af68ea0267bb24f1826cbc35358e22fc67f2eec5c7ebf91cb6392836a064" + solver-name = "gps-cdcl" + solver-version = 1 diff --git a/Gopkg.toml b/Gopkg.toml new file mode 100644 index 0000000..1ed8da5 --- /dev/null +++ b/Gopkg.toml @@ -0,0 +1,58 @@ +# Gopkg.toml example +# +# Refer to https://golang.github.io/dep/docs/Gopkg.toml.html +# for detailed Gopkg.toml documentation. +# +# required = ["github.com/user/thing/cmd/thing"] +# ignored = ["github.com/user/project/pkgX", "bitbucket.org/user/project/pkgA/pkgY"] +# +# [[constraint]] +# name = "github.com/user/project" +# version = "1.0.0" +# +# [[constraint]] +# name = "github.com/user/project2" +# branch = "dev" +# source = "github.com/myfork/project2" +# +# [[override]] +# name = "github.com/x/y" +# version = "2.4.0" +# +# [prune] +# non-go = false +# go-tests = true +# unused-packages = true + + +[[constraint]] + name = "github.com/NYTimes/gziphandler" + version = "1.0.1" + +[[constraint]] + name = "github.com/fgrosse/graphigo" + version = "2.0.0" + +[[constraint]] + name = "github.com/influxdata/influxdb" + version = "1.5.2" + +[[constraint]] + name = "github.com/naoina/toml" + version = "0.1.1" + +[[constraint]] + name = "github.com/pkg/errors" + version = "0.8.0" + +[[constraint]] + name = "github.com/spf13/cobra" + version = "0.0.2" + +[[constraint]] + name = "github.com/stretchr/testify" + version = "1.2.1" + +[prune] + go-tests = true + unused-packages = true diff --git a/circle.yml b/circle.yml index f915c43..8de86aa 100644 --- a/circle.yml +++ b/circle.yml @@ -6,7 +6,8 @@ jobs: working_directory: /go/src/github.com/FreifunkBremen/yanic steps: - checkout - - run: go get -t -d -v ./... + - run: curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh + - run: dep ensure - run: go install -ldflags "-X github.com/FreifunkBremen/yanic/cmd.VERSION=`git -C $GOPATH/src/github.com/FreifunkBremen/yanic rev-parse HEAD`" github.com/FreifunkBremen/yanic - store_artifacts: path: /go/bin/ @@ -17,7 +18,8 @@ jobs: working_directory: /go/src/github.com/FreifunkBremen/yanic steps: - checkout - - run: go get -t -d -v ./... + - run: curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh + - run: dep ensure - run: go get github.com/mattn/goveralls - run: go get golang.org/x/tools/cmd/cover - run: ./.test-coverage circle-ci @@ -30,7 +32,8 @@ jobs: working_directory: /go/src/github.com/FreifunkBremen/yanic steps: - checkout - - run: go get -t -d -v ./... + - run: curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh + - run: dep ensure - run: go test -race ./... workflows: version: 2