Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use /v2 for local package imports #100

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ transformation for LATIN-1 and UCS-2.

It is not fully compliant, there are some TODOs in the code.

Be sure to use `import "/github.com/fiorix/go-smpp/v2"`.

## Usage

Following is an SMPP client transmitter wrapped by an HTTP server
Expand Down
6 changes: 3 additions & 3 deletions cmd/sms/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ import (

"github.com/urfave/cli"

"github.com/fiorix/go-smpp/smpp"
"github.com/fiorix/go-smpp/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/smpp/pdu/pdutext"
"github.com/fiorix/go-smpp/v2/smpp"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdutext"
)

// Version of smppcli.
Expand Down
1 change: 0 additions & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ module github.com/fiorix/go-smpp/v2
go 1.15

require (
github.com/fiorix/go-smpp v0.0.0-20210403173735-2894b96e70ba
github.com/urfave/cli v1.22.5
golang.org/x/text v0.3.6
golang.org/x/time v0.0.0-20210220033141-f8bda1e9f3ba
Expand Down
3 changes: 1 addition & 2 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d h1:U+s90UTSYgptZMwQh2aRr3LuazLJIa+Pg3Kc1ylSYVY=
github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU=
github.com/fiorix/go-smpp v0.0.0-20210403173735-2894b96e70ba h1:vBqABUa2HUSc6tj22Tw+ZMVGHuBzKtljM38kbRanmrM=
github.com/fiorix/go-smpp v0.0.0-20210403173735-2894b96e70ba/go.mod h1:VfKFK7fGeCP81xEhbrOqUEh45n73Yy6jaPWwTVbxprI=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/russross/blackfriday/v2 v2.0.1 h1:lPqVAte+HuHNfhJ/0LC98ESWRz8afy9tM/0RK8m9o+Q=
github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
Expand Down
4 changes: 2 additions & 2 deletions smpp/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ import (
"sync"
"time"

"github.com/fiorix/go-smpp/smpp/pdu"
"github.com/fiorix/go-smpp/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/v2/smpp/pdu"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdufield"
)

// ConnStatus is an abstract interface for a connection status change.
Expand Down
2 changes: 1 addition & 1 deletion smpp/conn.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (
"net"
"sync"

"github.com/fiorix/go-smpp/smpp/pdu"
"github.com/fiorix/go-smpp/v2/smpp/pdu"
)

var (
Expand Down
6 changes: 3 additions & 3 deletions smpp/conn_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ package smpp
import (
"testing"

"github.com/fiorix/go-smpp/smpp/pdu"
"github.com/fiorix/go-smpp/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/smpp/smpptest"
"github.com/fiorix/go-smpp/v2/smpp/pdu"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/v2/smpp/smpptest"
)

func TestConn(t *testing.T) {
Expand Down
8 changes: 4 additions & 4 deletions smpp/example_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ import (

"golang.org/x/time/rate"

"github.com/fiorix/go-smpp/smpp"
"github.com/fiorix/go-smpp/smpp/pdu"
"github.com/fiorix/go-smpp/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/smpp/pdu/pdutext"
"github.com/fiorix/go-smpp/v2/smpp"
"github.com/fiorix/go-smpp/v2/smpp/pdu"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdutext"
)

func ExampleReceiver() {
Expand Down
4 changes: 2 additions & 2 deletions smpp/pdu/body.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ package pdu
import (
"io"

"github.com/fiorix/go-smpp/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/smpp/pdu/pdutlv"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdutlv"
)

// MaxSize is the maximum size allowed for a PDU.
Expand Down
4 changes: 2 additions & 2 deletions smpp/pdu/codec.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ import (
"io"
"sync/atomic"

"github.com/fiorix/go-smpp/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/smpp/pdu/pdutlv"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdutlv"
)

var nextSeq uint32
Expand Down
2 changes: 1 addition & 1 deletion smpp/pdu/pdufield/map.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ package pdufield
import (
"fmt"

"github.com/fiorix/go-smpp/smpp/pdu/pdutext"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdutext"
)

// Map is a collection of PDU field data indexed by name.
Expand Down
2 changes: 1 addition & 1 deletion smpp/pdu/pdufield/map_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"bytes"
"testing"

"github.com/fiorix/go-smpp/smpp/pdu/pdutext"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdutext"
)

func TestMapSet(t *testing.T) {
Expand Down
5 changes: 3 additions & 2 deletions smpp/pdu/pdutext/gsm7.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@
package pdutext

import (
"golang.org/x/text/transform"
"github.com/fiorix/go-smpp/smpp/encoding"
"github.com/fiorix/go-smpp/v2/smpp/encoding"

"golang.org/x/text/transform"
)

// GSM 7-bit (unpacked)
Expand Down
5 changes: 3 additions & 2 deletions smpp/pdu/pdutext/gsm7packed.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@
package pdutext

import (
"golang.org/x/text/transform"
"github.com/fiorix/go-smpp/smpp/encoding"
"github.com/fiorix/go-smpp/v2/smpp/encoding"

"golang.org/x/text/transform"
)

// GSM 7-bit (packed)
Expand Down
4 changes: 2 additions & 2 deletions smpp/pdu/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
package pdu

import (
"github.com/fiorix/go-smpp/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/smpp/pdu/pdutlv"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdutlv"
)

// PDU Types.
Expand Down
2 changes: 1 addition & 1 deletion smpp/pdu/types_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
"strconv"
"testing"

"github.com/fiorix/go-smpp/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdufield"
)

func TestBind(t *testing.T) {
Expand Down
4 changes: 2 additions & 2 deletions smpp/receiver.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ import (
"sync"
"time"

"github.com/fiorix/go-smpp/smpp/pdu"
"github.com/fiorix/go-smpp/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/v2/smpp/pdu"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdufield"
)

// Receiver implements an SMPP client receiver.
Expand Down
4 changes: 2 additions & 2 deletions smpp/receiver_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import (
"testing"
"time"

"github.com/fiorix/go-smpp/smpp/pdu"
"github.com/fiorix/go-smpp/smpp/smpptest"
"github.com/fiorix/go-smpp/v2/smpp/pdu"
"github.com/fiorix/go-smpp/v2/smpp/smpptest"
)

func TestReceiver(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion smpp/smpptest/conn.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
"io"
"net"

"github.com/fiorix/go-smpp/smpp/pdu"
"github.com/fiorix/go-smpp/v2/smpp/pdu"
)

// Conn implements a server side connection.
Expand Down
4 changes: 2 additions & 2 deletions smpp/smpptest/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ import (
"net"
"sync"

"github.com/fiorix/go-smpp/smpp/pdu"
"github.com/fiorix/go-smpp/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/v2/smpp/pdu"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdufield"
)

// Default settings.
Expand Down
8 changes: 4 additions & 4 deletions smpp/smpptest/server_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ import (
"net"
"testing"

"github.com/fiorix/go-smpp/smpp/pdu"
"github.com/fiorix/go-smpp/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/smpp/pdu/pdutext"
"github.com/fiorix/go-smpp/smpp/pdu/pdutlv"
"github.com/fiorix/go-smpp/v2/smpp/pdu"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdutext"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdutlv"
)

func TestServer(t *testing.T) {
Expand Down
4 changes: 2 additions & 2 deletions smpp/transceiver.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ import (
"math/rand"
"time"

"github.com/fiorix/go-smpp/smpp/pdu"
"github.com/fiorix/go-smpp/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/v2/smpp/pdu"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdufield"
)

// Transceiver implements an SMPP transceiver.
Expand Down
8 changes: 4 additions & 4 deletions smpp/transceiver_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ import (

"golang.org/x/time/rate"

"github.com/fiorix/go-smpp/smpp/pdu"
"github.com/fiorix/go-smpp/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/smpp/pdu/pdutext"
"github.com/fiorix/go-smpp/smpp/smpptest"
"github.com/fiorix/go-smpp/v2/smpp/pdu"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdutext"
"github.com/fiorix/go-smpp/v2/smpp/smpptest"
)

func TestTransceiver(t *testing.T) {
Expand Down
8 changes: 4 additions & 4 deletions smpp/transmitter.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ import (
"sync/atomic"
"time"

"github.com/fiorix/go-smpp/smpp/pdu"
"github.com/fiorix/go-smpp/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/smpp/pdu/pdutext"
"github.com/fiorix/go-smpp/smpp/pdu/pdutlv"
"github.com/fiorix/go-smpp/v2/smpp/pdu"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdutext"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdutlv"
)

// ErrMaxWindowSize is returned when an operation (such as Submit) violates
Expand Down
8 changes: 4 additions & 4 deletions smpp/transmitter_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ import (

"golang.org/x/time/rate"

"github.com/fiorix/go-smpp/smpp/pdu"
"github.com/fiorix/go-smpp/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/smpp/pdu/pdutext"
"github.com/fiorix/go-smpp/smpp/smpptest"
"github.com/fiorix/go-smpp/v2/smpp/pdu"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdufield"
"github.com/fiorix/go-smpp/v2/smpp/pdu/pdutext"
"github.com/fiorix/go-smpp/v2/smpp/smpptest"
)

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