Skip to content

Commit

Permalink
Switch to go modules (#5)
Browse files Browse the repository at this point in the history
  • Loading branch information
Fauzyy authored Jul 23, 2019
1 parent 2ce1287 commit 01a1647
Show file tree
Hide file tree
Showing 17 changed files with 84 additions and 187 deletions.
50 changes: 19 additions & 31 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,46 +1,34 @@
aliases:
- &dep_ensure
name: dep_ensure
command: |
go get -u github.com/golang/dep/cmd/dep
dep ensure
defaults: &defaults
working_directory: /go/src/github.com/coretech/terrafile
working_directory: /go/src/github.com/segmentio/terrafile
docker:
- image: circleci/golang:1.11.1
- image: circleci/golang:1.12.1

version: 2
jobs:
build:
<<: *defaults
<<: *defaults
steps:
- checkout
- run: *dep_ensure
- run:
name: build_and_test
command: |
go build -v
go test -v
deploy:
<<: *defaults
steps:
- checkout
- run: *dep_ensure
- run: curl -sL https://git.io/goreleaser | bash
GO111MODULE=on go build -v
GO111MODULE=on go test -v
- run:
name: Check modules are tidy and checked in
command: |
export GO111MODULE=on
go mod tidy
go mod vendor
if [ "$(git status --porcelain)" != "" ]; then
echo "git tree is dirty after tidying and vendoring modules"
echo "ensure go.mod and go.sum are tidy and vendor is checked in"
git status
exit 1
fi
workflows:
version: 2
release:
jobs:
- build:
filters: # required since `deploy` has tag filters AND requires `build`
tags:
only: /.*/
- deploy:
requires:
- build
filters:
tags:
only: /^v.*/
branches:
ignore: /.*/
- build
107 changes: 0 additions & 107 deletions Gopkg.lock

This file was deleted.

49 changes: 0 additions & 49 deletions Gopkg.toml

This file was deleted.

15 changes: 15 additions & 0 deletions go.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
module github.com/segmentio/terrafile

go 1.12

require (
github.com/jessevdk/go-flags v1.4.0
github.com/konsorten/go-windows-terminal-sequences v1.0.1 // indirect
github.com/nritholtz/stdemuxerhook v0.0.0-20181016194454-2c86ca05d211
github.com/rendon/testcli v0.0.0-20161027181003-6283090d169f
github.com/sirupsen/logrus v1.1.1
github.com/stretchr/testify v1.2.2
golang.org/x/crypto v0.0.0-20181015023909-0c41d7ab0a0e // indirect
golang.org/x/sys v0.0.0-20181011152604-fa43e7bc11ba // indirect
gopkg.in/yaml.v2 v2.2.1
)
27 changes: 27 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/jessevdk/go-flags v1.4.0 h1:4IU2WS7AumrZ/40jfhf4QVDMsQwqA7VEHozFRrGARJA=
github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI=
github.com/konsorten/go-windows-terminal-sequences v0.0.0-20180402223658-b729f2633dfe/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
github.com/konsorten/go-windows-terminal-sequences v1.0.1 h1:mweAR1A6xJ3oS2pRaGiHgQ4OO8tzTaLawm8vnODuwDk=
github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
github.com/nritholtz/stdemuxerhook v0.0.0-20181016194454-2c86ca05d211 h1:/i5qSLHu6rwA42AvHpVWZGnmMXv2N8EEid2VjA5Hxco=
github.com/nritholtz/stdemuxerhook v0.0.0-20181016194454-2c86ca05d211/go.mod h1:Kd+I8uDa0G2Ui+K1G4dSvv5/S0JP/clMLLMph0SxVQA=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/rendon/testcli v0.0.0-20161027181003-6283090d169f h1:onGP+qmYmjKs7pkmi9j0mwyr97/D5wki80e74aKIOxg=
github.com/rendon/testcli v0.0.0-20161027181003-6283090d169f/go.mod h1:cq57a4l475CeMvE7RRpSui1MEqCmhirIt1E7kl8BC2Q=
github.com/sirupsen/logrus v1.1.1 h1:VzGj7lhU7KEB9e9gMpAV/v5XT2NVSvLJhJLCWbnkgXg=
github.com/sirupsen/logrus v1.1.1/go.mod h1:zrgwTnHtNr00buQ1vSptGe8m1f/BbgsPukg8qsT7A+A=
github.com/stretchr/testify v1.2.2 h1:bSDNvY7ZPG5RlJ8otE/7V6gMiyenm9RtJ7IUVIAoJ1w=
github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
golang.org/x/crypto v0.0.0-20181015023909-0c41d7ab0a0e h1:IzypfodbhbnViNUO/MEh0FzCUooG97cIGfdggUrUSyU=
golang.org/x/crypto v0.0.0-20181015023909-0c41d7ab0a0e/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20181011152604-fa43e7bc11ba h1:nZJIJPGow0Kf9bU9QTc1U6OXbs/7Hu4e+cNv+hxH+Zc=
golang.org/x/sys v0.0.0-20181011152604-fa43e7bc11ba/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/yaml.v2 v2.2.1 h1:mUhvW9EsL+naU5Q3cakzfE91YhliOondGd6ZrsDBHQE=
gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
Empty file modified vendor/github.com/jessevdk/go-flags/check_crosscompile.sh
100755 → 100644
Empty file.
Empty file modified vendor/golang.org/x/sys/unix/mkall.sh
100755 → 100644
Empty file.
Empty file modified vendor/golang.org/x/sys/unix/mkerrors.sh
100755 → 100644
Empty file.
Empty file modified vendor/golang.org/x/sys/unix/mksyscall.pl
100755 → 100644
Empty file.
Empty file modified vendor/golang.org/x/sys/unix/mksyscall_solaris.pl
100755 → 100644
Empty file.
Empty file modified vendor/golang.org/x/sys/unix/mksysctl_openbsd.pl
100755 → 100644
Empty file.
Empty file modified vendor/golang.org/x/sys/unix/mksysnum_darwin.pl
100755 → 100644
Empty file.
Empty file modified vendor/golang.org/x/sys/unix/mksysnum_dragonfly.pl
100755 → 100644
Empty file.
Empty file modified vendor/golang.org/x/sys/unix/mksysnum_freebsd.pl
100755 → 100644
Empty file.
Empty file modified vendor/golang.org/x/sys/unix/mksysnum_netbsd.pl
100755 → 100644
Empty file.
Empty file modified vendor/golang.org/x/sys/unix/mksysnum_openbsd.pl
100755 → 100644
Empty file.
23 changes: 23 additions & 0 deletions vendor/modules.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# github.com/davecgh/go-spew v1.1.1
github.com/davecgh/go-spew/spew
# github.com/jessevdk/go-flags v1.4.0
github.com/jessevdk/go-flags
# github.com/konsorten/go-windows-terminal-sequences v1.0.1
github.com/konsorten/go-windows-terminal-sequences
# github.com/nritholtz/stdemuxerhook v0.0.0-20181016194454-2c86ca05d211
github.com/nritholtz/stdemuxerhook
# github.com/pmezard/go-difflib v1.0.0
github.com/pmezard/go-difflib/difflib
# github.com/rendon/testcli v0.0.0-20161027181003-6283090d169f
github.com/rendon/testcli
# github.com/sirupsen/logrus v1.1.1
github.com/sirupsen/logrus
# github.com/stretchr/testify v1.2.2
github.com/stretchr/testify/assert
# golang.org/x/crypto v0.0.0-20181015023909-0c41d7ab0a0e
golang.org/x/crypto/ssh/terminal
# golang.org/x/sys v0.0.0-20181011152604-fa43e7bc11ba
golang.org/x/sys/unix
golang.org/x/sys/windows
# gopkg.in/yaml.v2 v2.2.1
gopkg.in/yaml.v2

0 comments on commit 01a1647

Please sign in to comment.