Skip to content

Commit ea4fe68

Browse files
authored
Move to go modules (#91)
1 parent d2ce263 commit ea4fe68

File tree

15 files changed

+118
-102
lines changed

15 files changed

+118
-102
lines changed

.travis.yml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,11 @@ before_script:
2020
- ./cc-test-reporter before-build
2121

2222
install:
23-
- wget https://github.com/go-task/task/releases/download/v2.5.0/task_linux_amd64.tar.gz
24-
- tar xf task_linux_amd64.tar.gz
25-
- mv task $HOME/gopath/bin
23+
- curl -sL https://taskfile.dev/install.sh | sh
2624

2725
script:
28-
- diff -u <(echo -n) <(task lint)
29-
- task test-coverage
26+
- diff -u <(echo -n) <(./bin/task lint)
27+
- ./bin/task test-coverage
3028

3129
after_script:
3230
- ./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT

Gopkg.lock

Lines changed: 0 additions & 39 deletions
This file was deleted.

Gopkg.toml

Lines changed: 0 additions & 8 deletions
This file was deleted.

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ To update Objx to the latest version, run:
7474
go get -u github.com/stretchr/objx
7575

7676
### Supported go versions
77-
We support the lastest three major Go versions, which are 1.9, 1.10 and 1.11 at the moment.
77+
We support the lastest three major Go versions, which are 1.10, 1.11 and 1.12 at the moment.
7878

7979
## Contributing
8080
Please feel free to submit issues, fork the repository and send pull requests!

Taskfile.yml

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,30 @@
1-
default:
2-
deps: [test]
1+
version: '2'
32

4-
update-deps:
5-
desc: Updates dependencies
6-
cmds:
7-
- dep ensure
8-
- dep ensure -update
3+
env:
4+
GOFLAGS: -mod=vendor
95

10-
lint:
11-
desc: Checks code style
12-
cmds:
13-
- gofmt -d -s *.go
14-
- go vet .
15-
silent: true
6+
tasks:
7+
default:
8+
deps: [test]
169

17-
lint-fix:
18-
desc: Fixes code style
19-
cmds:
20-
- gofmt -w -s *.go
10+
lint:
11+
desc: Checks code style
12+
cmds:
13+
- gofmt -d -s *.go
14+
- go vet ./...
15+
silent: true
2116

22-
test:
23-
desc: Runs go tests
24-
cmds:
25-
- go test -race .
17+
lint-fix:
18+
desc: Fixes code style
19+
cmds:
20+
- gofmt -w -s *.go
2621

27-
test-coverage:
28-
desc: Runs go tests and calucates test coverage
29-
cmds:
30-
- go test -coverprofile=c.out .
22+
test:
23+
desc: Runs go tests
24+
cmds:
25+
- go test -race ./...
26+
27+
test-coverage:
28+
desc: Runs go tests and calucates test coverage
29+
cmds:
30+
- go test -race -coverprofile=c.out ./...

go.mod

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
module github.com/stretchr/objx
2+
3+
go 1.12
4+
5+
require (
6+
github.com/davecgh/go-spew v1.1.1 // indirect
7+
github.com/stretchr/testify v1.3.0
8+
)

go.sum

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
2+
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
3+
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
4+
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
5+
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
6+
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
7+
github.com/stretchr/testify v1.3.0 h1:TivCn/peBQ7UY8ooIcPgZFpTNSz0Q2U6UrFlUfqbe0Q=
8+
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=

vendor/github.com/stretchr/testify/LICENSE

Lines changed: 17 additions & 18 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/stretchr/testify/assert/assertion_format.go.tmpl

Lines changed: 5 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/stretchr/testify/assert/assertion_forward.go.tmpl

Lines changed: 5 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)