Skip to content
This repository was archived by the owner on Dec 7, 2019. It is now read-only.

Commit e2f5000

Browse files
committed
rename moved pkg alias to core; upgrade deps.
1 parent 290882d commit e2f5000

File tree

5 files changed

+23
-25
lines changed

5 files changed

+23
-25
lines changed

deprecated.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
package connsec
22

3-
import moved "github.com/libp2p/go-libp2p-core/sec"
3+
import core "github.com/libp2p/go-libp2p-core/sec"
44

55
// Deprecated: Use github.com/libp2p/go-libp2p-core/sec.SecureTransport instead.
6-
type Transport = moved.SecureTransport
6+
type Transport = core.SecureTransport
77

88
// Deprecated: Use github.com/libp2p/go-libp2p-core/sec.SecureConn instead.
9-
type Conn = moved.SecureConn
9+
type Conn = core.SecureConn

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
module github.com/libp2p/go-conn-security
22

33
require (
4-
github.com/libp2p/go-libp2p-core v0.0.0-20190417162149-f41b5dd7c01b
4+
github.com/libp2p/go-libp2p-core v0.0.0-20190422125857-3a54eb68d178
55
golang.org/x/crypto v0.0.0-20190228161510-8dd112bcdc25 // indirect
66
golang.org/x/sys v0.0.0-20190228124157-a34e9553db1e // indirect
77
)

go.sum

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,8 @@ github.com/kkdai/bstream v0.0.0-20161212061736-f391b8402d23/go.mod h1:J+Gs4SYgM6
3131
github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
3232
github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
3333
github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
34-
github.com/libp2p/go-libp2p-core v0.0.0-20190417162149-f41b5dd7c01b h1:G7jk8dtQP5NeK5uckxMarWHNH0bTTDpSUMPUQwGtFEU=
35-
github.com/libp2p/go-libp2p-core v0.0.0-20190417162149-f41b5dd7c01b/go.mod h1:4iqSipG3tx8vB0FVHHRPVl6/lZqPht2Lhd/ZBlIGNSo=
36-
github.com/libp2p/go-libp2p-crypto v0.0.1 h1:JNQd8CmoGTohO/akqrH16ewsqZpci2CbgYH/LmYl8gw=
37-
github.com/libp2p/go-libp2p-crypto v0.0.1/go.mod h1:yJkNyDmO341d5wwXxDUGO0LykUVT72ImHNUqh5D/dBE=
34+
github.com/libp2p/go-libp2p-core v0.0.0-20190422125857-3a54eb68d178 h1:+wsyafI3SBZy7fMT8bTdHyrzKnPJfDShnbfjxXM3uqk=
35+
github.com/libp2p/go-libp2p-core v0.0.0-20190422125857-3a54eb68d178/go.mod h1:GYAqGjbAd2HxtkR5D6HsOp1ZPBrGvCD0eCLX8rQtNMw=
3836
github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1 h1:lYpkrQH5ajf0OXOcUbGjvZxxijuBwbbmlSxLiuofa+g=
3937
github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1/go.mod h1:pD8RvIylQ358TN4wwqatJ8rNavkEINozVn9DtGI3dfQ=
4038
github.com/minio/sha256-simd v0.0.0-20190131020904-2d45a736cd16 h1:5W7KhL8HVF3XCFOweFD3BNESdnO8ewyYTFT2R+/b8FQ=

insecure/deprecated.go

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,19 @@ package insecure
22

33
import (
44
"github.com/libp2p/go-libp2p-core/peer"
5-
moved "github.com/libp2p/go-libp2p-core/sec/insecure"
5+
core "github.com/libp2p/go-libp2p-core/sec/insecure"
66
)
77

88
// Deprecated: Use github.com/libp2p/go-libp2p-core/sec/insecure.ID instead.
9-
const ID = moved.ID
9+
const ID = core.ID
1010

1111
// Deprecated: Use github.com/libp2p/go-libp2p-core/sec/insecure.Transport instead.
12-
type Transport = moved.Transport
12+
type Transport = core.Transport
1313

1414
// Deprecated: Use github.com/libp2p/go-libp2p-core/sec/insecure.New instead.
15-
func New(id peer.ID) *moved.Transport {
16-
return moved.New(id)
15+
func New(id peer.ID) *core.Transport {
16+
return core.New(id)
1717
}
1818

1919
// Deprecated: Use github.com/libp2p/go-libp2p-core/sec/insecure.Conn instead.
20-
type Conn = moved.Conn
20+
type Conn = core.Conn

test/deprecated.go

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -6,51 +6,51 @@ import (
66
"github.com/libp2p/go-libp2p-core/peer"
77
"github.com/libp2p/go-libp2p-core/sec"
88

9-
moved "github.com/libp2p/go-libp2p-core/sec/test"
9+
core "github.com/libp2p/go-libp2p-core/sec/test"
1010
)
1111

1212
// Deprecated: Use github.com/libp2p/go-libp2p-core/sec/test.Subtests instead.
13-
var Subtests = moved.Subtests
13+
var Subtests = core.Subtests
1414

1515
// Deprecated: Use github.com/libp2p/go-libp2p-core/sec/test.TestMessage instead.
16-
var TestMessage = moved.TestMessage
16+
var TestMessage = core.TestMessage
1717

1818
// Deprecated: Use github.com/libp2p/go-libp2p-core/sec/test.TestStreamLen instead.
1919
// Warning: it's impossible to alias a var in go, so reads and writes to this variable may be inaccurate
2020
// or not have the intended effect.
21-
var TestStreamLen = moved.TestStreamLen
21+
var TestStreamLen = core.TestStreamLen
2222

2323
// Deprecated: Use github.com/libp2p/go-libp2p-core/sec/test.TestSeed instead.
2424
// Warning: it's impossible to alias a var in go, so reads and writes to this variable may be inaccurate
2525
// or not have the intended effect.
26-
var TestSeed = moved.TestSeed
26+
var TestSeed = core.TestSeed
2727

2828
// Deprecated: Use github.com/libp2p/go-libp2p-core/sec/test.SubtestAll instead.
2929
func SubtestAll(t *testing.T, at, bt sec.SecureTransport, ap, bp peer.ID) {
30-
moved.SubtestAll(t, at, bt, ap, bp)
30+
core.SubtestAll(t, at, bt, ap, bp)
3131
}
3232

3333
// Deprecated: Use github.com/libp2p/go-libp2p-core/sec/test.SubtestKeys instead.
3434
func SubtestKeys(t *testing.T, at, bt sec.SecureTransport, ap, bp peer.ID) {
35-
moved.SubtestKeys(t, at, bt, ap, bp)
35+
core.SubtestKeys(t, at, bt, ap, bp)
3636
}
3737

3838
// Deprecated: Use github.com/libp2p/go-libp2p-core/sec/test.SubtestWrongPeer instead.
3939
func SubtestWrongPeer(t *testing.T, at, bt sec.SecureTransport, ap, bp peer.ID) {
40-
moved.SubtestWrongPeer(t, at, bt, ap, bp)
40+
core.SubtestWrongPeer(t, at, bt, ap, bp)
4141
}
4242

4343
// Deprecated: Use github.com/libp2p/go-libp2p-core/sec/test.SubtestCancelHandshakeOutbound instead.
4444
func SubtestCancelHandshakeOutbound(t *testing.T, at, bt sec.SecureTransport, ap, bp peer.ID) {
45-
moved.SubtestCancelHandshakeOutbound(t, at, bt, ap, bp)
45+
core.SubtestCancelHandshakeOutbound(t, at, bt, ap, bp)
4646
}
4747

4848
// Deprecated: Use github.com/libp2p/go-libp2p-core/sec/test.SubtestCancelHandshakeInbound instead.
4949
func SubtestCancelHandshakeInbound(t *testing.T, at, bt sec.SecureTransport, ap, bp peer.ID) {
50-
moved.SubtestCancelHandshakeInbound(t, at, bt, ap, bp)
50+
core.SubtestCancelHandshakeInbound(t, at, bt, ap, bp)
5151
}
5252

5353
// Deprecated: Use github.com/libp2p/go-libp2p-core/sec/test.SubtestStream instead.
5454
func SubtestStream(t *testing.T, at, bt sec.SecureTransport, ap, bp peer.ID) {
55-
moved.SubtestStream(t, at, bt, ap, bp)
55+
core.SubtestStream(t, at, bt, ap, bp)
5656
}

0 commit comments

Comments
 (0)