Skip to content

Commit

Permalink
Upgrade gotils, update .travis.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
Sergio Andres Virviescas Santana committed Jun 8, 2020
1 parent 5c63aec commit 0ad7f87
Show file tree
Hide file tree
Showing 4 changed files with 53 additions and 51 deletions.
24 changes: 18 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,10 +1,22 @@
.vscode/
# Binaries for programs and plugins
*.exe
*.exe~
*.dll
*.so
*.dylib

# Test binary, built with `go test -c`
*.test

pkg/
build/
bin/
examples/
# Output of the go coverage tool, specifically when used with LiteIDE
*.out
.coverprofile

# Dependency directories (remove the comment below to include it)
vendor/

*.fasthttp.gz
# IDE
.vscode/

# Examples
_examples/
62 changes: 26 additions & 36 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,47 +1,37 @@
language: go
sudo: false
go:
- 1.9.x
- 1.10.x
- 1.11.x
- 1.12.x
- 1.13.x
- 1.14.x
- tip

os:
- linux
- osx
- windows

go:
- 1.14.x
- 1.13.x
- 1.12.x
- 1.11.x
- tip

before_install:
- curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.27.0
- go get -u -v github.com/mattn/goveralls
- go get -v
before_script:
- go get -t -v ./...

script:
# lint (go version >= 1.11, gotip not supported)
- |
if [[ $(go version | awk '{print $3}') =~ ^go1.1[1-9]$ ]]; then
golangci-lint run
fi
- go test -v -cover -race ./...

# build test for supported platforms
- GOOS=linux go build
- GOOS=darwin go build
- GOOS=freebsd go build
- GOOS=windows go build
- |
if [[ $(uname) == Darwin ]]; then
# Last supported version for GOOS=386 is go1.14 in Darwin
if [[ $(go version | awk '{print $3}') =~ ^go1\.(9|10|11|12|13|14)$ ]]; then
GOARCH=386 go build
fi
else
GOARCH=386 go build
fi
jobs:
allow_failures:
- go: tip

# run tests
- go test -v -cover -race -coverprofile=.coverprofile
include:
- stage: lint
script:
- curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.27.0
- golangci-lint run

# send coverage
- $HOME/gopath/bin/goveralls -coverprofile=.coverprofile -service=travis-ci
- stage: cross compilation
script:
- GOOS=linux go build
- GOOS=darwin go build
- GOOS=freebsd go build
- GOOS=windows go build
- GOARCH=386 go build
6 changes: 3 additions & 3 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ go 1.11

require (
github.com/atreugo/mock v0.0.0-20200601091009-13c275b330b0
github.com/fasthttp/router v1.1.6
github.com/savsgio/go-logger/v2 v2.0.0
github.com/savsgio/gotils v0.0.0-20200413113635-8c468ce75cca
github.com/fasthttp/router v1.1.7
github.com/savsgio/go-logger/v2 v2.0.1
github.com/savsgio/gotils v0.0.0-20200608092407-b1456038b6ca
github.com/valyala/bytebufferpool v1.0.0
github.com/valyala/fasthttp v1.14.0
)
12 changes: 6 additions & 6 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@ github.com/andybalholm/brotli v1.0.0 h1:7UCwP93aiSfvWpapti8g88vVVGp2qqtGyePsSuDa
github.com/andybalholm/brotli v1.0.0/go.mod h1:loMXtMfwqflxFJPmdbJO0a3KNoPuLBgiu3qAvBg8x/Y=
github.com/atreugo/mock v0.0.0-20200601091009-13c275b330b0 h1:IVqe9WnancrkICl5HqEfGjrnkQ4+VsU5fodcuFVoG/A=
github.com/atreugo/mock v0.0.0-20200601091009-13c275b330b0/go.mod h1:HTHAc8RoZXMVTr6wZQN7Jjm3mYMnbfkqqKdnQgSoe9o=
github.com/fasthttp/router v1.1.6 h1:lBcXxp1ZNoNbSeh4+RvAaXKSEiHU6sGd+gEMpd5Xjog=
github.com/fasthttp/router v1.1.6/go.mod h1:E1mpv7mrQzAhiSQdqhRb+GBTC7MEV+bLFVmgzSA5oFM=
github.com/fasthttp/router v1.1.7 h1:1Wt3iK7yILMNUlgWg3kfqNW8cQhvMIgkqKUhh370wR4=
github.com/fasthttp/router v1.1.7/go.mod h1:GllqmaKtAsIvYwz5Nbu0qcbQQXBSVaeXw2KY3SmlbYM=
github.com/klauspost/compress v1.10.4 h1:jFzIFaf586tquEB5EhzQG0HwGNSlgAJpG53G6Ss11wc=
github.com/klauspost/compress v1.10.4/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs=
github.com/savsgio/go-logger/v2 v2.0.0 h1:9CzMIHfAzHoMJoY+0ODI9DJGfBxRIVqI7jZkg47MRrQ=
github.com/savsgio/go-logger/v2 v2.0.0/go.mod h1:fog+sZsg75Or4EENyd1jrS/Ps44s39hd6lccqALz0C8=
github.com/savsgio/gotils v0.0.0-20200413113635-8c468ce75cca h1:Qe7Mtuhjkk38HVpRtvWdziZJcwG3Qup1mfyvyOrcnyM=
github.com/savsgio/gotils v0.0.0-20200413113635-8c468ce75cca/go.mod h1:TWNAOTaVzGOXq8RbEvHnhzA/A2sLZzgn0m6URjnukY8=
github.com/savsgio/go-logger/v2 v2.0.1 h1:MgmsI5hnQFz0n5oX1Do/T9DldTo60guQTGwlRpzk0mk=
github.com/savsgio/go-logger/v2 v2.0.1/go.mod h1:fog+sZsg75Or4EENyd1jrS/Ps44s39hd6lccqALz0C8=
github.com/savsgio/gotils v0.0.0-20200608092407-b1456038b6ca h1:fHGQex3/DBt5QH/ZpMCseG2ytKjCiISEkMD4RMT51Dg=
github.com/savsgio/gotils v0.0.0-20200608092407-b1456038b6ca/go.mod h1:TWNAOTaVzGOXq8RbEvHnhzA/A2sLZzgn0m6URjnukY8=
github.com/valyala/bytebufferpool v1.0.0 h1:GqA5TC/0021Y/b9FG4Oi9Mr3q7XYx6KllzawFIhcdPw=
github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc=
github.com/valyala/fasthttp v1.14.0 h1:67bfuW9azCMwW/Jlq/C+VeihNpAuJMWkYPBig1gdi3A=
Expand Down

0 comments on commit 0ad7f87

Please sign in to comment.