Skip to content

Commit

Permalink
Go mod (s12v#1)
Browse files Browse the repository at this point in the history
  • Loading branch information
s12v authored May 10, 2019
1 parent f1e704a commit a674b38
Show file tree
Hide file tree
Showing 12 changed files with 44 additions and 75 deletions.
11 changes: 4 additions & 7 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,13 @@
language: go

go:
- "1.8"
- "1.9"
- "1.10"
- "1.12"

install:
- curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
- dep ensure
env:
- GO111MODULE=on

script:
- go test . -v -coverprofile=coverage.txt -covermode=atomic
- make

after_success:
- bash <(curl -s https://codecov.io/bash)
51 changes: 0 additions & 51 deletions Gopkg.lock

This file was deleted.

11 changes: 0 additions & 11 deletions Gopkg.toml

This file was deleted.

8 changes: 8 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
.PHONY: all
all: clean test

clean:
rm -rf ./bin || true

test:
go test -v ./... -coverprofile=coverage.txt -covermode=atomic
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,10 @@ A Go library to retrieve RSA public keys from a JWKS (JSON Web Key Set) endpoint

## Installation

Using [Go modules](https://github.com/golang/go/wiki/Modules)

```bash
dep ensure --add "github.com/s12v/go-jwks@v0.1.1"
go get github.com/s12v/go-jwks@v0.2.0
```

## Dependencies
Expand Down
2 changes: 1 addition & 1 deletion cache.go
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package jwks

import (
"fmt"
"github.com/patrickmn/go-cache"
"time"
"fmt"
)

type Cache interface {
Expand Down
2 changes: 1 addition & 1 deletion cache_test.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package jwks

import (
"testing"
"github.com/patrickmn/go-cache"
"testing"
"time"
)

Expand Down
2 changes: 1 addition & 1 deletion client.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import (
"fmt"
"github.com/square/go-jose"
"golang.org/x/sync/semaphore"
"time"
"log"
"time"
)

type JWKSClient interface {
Expand Down
2 changes: 1 addition & 1 deletion client_test.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package jwks

import (
"testing"
"github.com/square/go-jose"
"testing"
"time"
)

Expand Down
12 changes: 12 additions & 0 deletions go.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
module github.com/s12v/go-jwks

go 1.12

require (
github.com/patrickmn/go-cache v2.1.0+incompatible
github.com/square/go-jose v2.1.6+incompatible
golang.org/x/crypto v0.0.0-20180621125126-a49355c7e3f8
golang.org/x/net v0.0.0-20180729183719-c4299a1a0d85
golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f
gopkg.in/square/go-jose.v2 v2.3.1 // indirect
)
12 changes: 12 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
github.com/patrickmn/go-cache v2.1.0+incompatible h1:HRMgzkcYKYpi3C8ajMPV8OFXaaRUnok+kx1WdO15EQc=
github.com/patrickmn/go-cache v2.1.0+incompatible/go.mod h1:3Qf8kWWT7OJRJbdiICTKqZju1ZixQ/KpMGzzAfe6+WQ=
github.com/square/go-jose v2.1.6+incompatible h1:vlXeaqoFPTA+Q4bWegkZ8PhPq6Ke9np2Bkyi09tMdQc=
github.com/square/go-jose v2.1.6+incompatible/go.mod h1:7MxpAF/1WTVUu8Am+T5kNy+t0902CaLWM4Z745MkOa8=
golang.org/x/crypto v0.0.0-20180621125126-a49355c7e3f8 h1:h7zdf0RiEvWbYBKIx4b+q41xoUVnMmvsGZnIVE5syG8=
golang.org/x/crypto v0.0.0-20180621125126-a49355c7e3f8/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
golang.org/x/net v0.0.0-20180729183719-c4299a1a0d85 h1:L8D6kGKB6IflRbLijfnSTkgmss6PZ/Q2MG7XefweZB4=
golang.org/x/net v0.0.0-20180729183719-c4299a1a0d85/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f h1:wMNYb4v58l5UBM7MYRLPG6ZhfOqbKu7X5eyFl8ZhKvA=
golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
gopkg.in/square/go-jose.v2 v2.3.1 h1:SK5KegNXmKmqE342YYN2qPHEnUYeoMiXXl1poUlI+o4=
gopkg.in/square/go-jose.v2 v2.3.1/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI=
2 changes: 1 addition & 1 deletion source.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import (
"encoding/json"
"fmt"
"github.com/square/go-jose"
"net/http"
"log"
"net/http"
)

type JWKSSource interface {
Expand Down

0 comments on commit a674b38

Please sign in to comment.