Skip to content

Commit

Permalink
update import path
Browse files Browse the repository at this point in the history
  • Loading branch information
LyricTian committed Jun 13, 2018
1 parent 898db00 commit 28fbf41
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 12 deletions.
8 changes: 6 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ go_import_path: github.com/go-session/echo-session
go:
- 1.9
before_install:
- go get github.com/mattn/goveralls
- go get -t -v ./...

script:
- $HOME/gopath/bin/goveralls -service=travis-ci
- go test -race -coverprofile=coverage.txt -covermode=atomic

after_success:
- bash <(curl -s https://codecov.io/bash)
13 changes: 5 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Session middleware for [Echo](https://github.com/labstack/echo)

[![Build][Build-Status-Image]][Build-Status-Url] [![Coverage][Coverage-Image]][Coverage-Url] [![ReportCard][reportcard-image]][reportcard-url] [![GoDoc][godoc-image]][godoc-url] [![License][license-image]][license-url]
[![Build][Build-Status-Image]][Build-Status-Url] [![Codecov][codecov-image]][codecov-url] [![ReportCard][reportcard-image]][reportcard-url] [![GoDoc][godoc-image]][godoc-url] [![License][license-image]][license-url]

## Quick Start

Expand All @@ -21,16 +21,13 @@ import (

"github.com/go-session/echo-session"
"github.com/labstack/echo"
"gopkg.in/session.v2"
"github.com/go-session/session"
)

func main() {
e := echo.New()

e.Use(echosession.New(
session.SetCookieName("session_id"),
session.SetSign([]byte("sign")),
))
e.Use(echosession.New())

e.GET("/", func(ctx echo.Context) error {
store := echosession.FromContext(ctx)
Expand Down Expand Up @@ -75,8 +72,8 @@ $ ./server

[Build-Status-Url]: https://travis-ci.org/go-session/echo-session
[Build-Status-Image]: https://travis-ci.org/go-session/echo-session.svg?branch=master
[Coverage-Url]: https://coveralls.io/github/go-session/echo-session?branch=master
[Coverage-Image]: https://coveralls.io/repos/github/go-session/echo-session/badge.svg?branch=master
[codecov-url]: https://codecov.io/gh/go-session/echo-session
[codecov-image]: https://codecov.io/gh/go-session/echo-session/branch/master/graph/badge.svg
[reportcard-url]: https://goreportcard.com/report/github.com/go-session/echo-session
[reportcard-image]: https://goreportcard.com/badge/github.com/go-session/echo-session
[godoc-url]: https://godoc.org/github.com/go-session/echo-session
Expand Down
2 changes: 1 addition & 1 deletion session.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import (
"context"
"sync"

"github.com/go-session/session"
"github.com/labstack/echo"
"gopkg.in/session.v2"
)

type (
Expand Down
2 changes: 1 addition & 1 deletion session_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import (
"net/http/httptest"
"testing"

"github.com/go-session/session"
"github.com/labstack/echo"
"gopkg.in/session.v2"
)

func TestSession(t *testing.T) {
Expand Down

0 comments on commit 28fbf41

Please sign in to comment.