Create messaging package and move some packages into it (#1505)

This commit is contained in:
Adam Babik 2019-06-26 20:17:41 +02:00 committed by GitHub
parent 1ab2e88bf5
commit e28d4ef1a3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
41 changed files with 48 additions and 48 deletions

View File

@ -15,7 +15,7 @@ checks:
# Functions or methods that may be hard to understand. This is disabled as it doesn't appear to be a reliable metric.
method-complexity:
enabled: false
# Classes defined with a high number of functions or methods.
# Classes defined with a high number of functions or methods.
method-count:
config:
threshold: 20
@ -42,4 +42,4 @@ exclude_patterns:
- static/
- t/
- mailserver/migrations
- services/shhext/chat/migrations
- messaging/chat/migrations

View File

@ -172,7 +172,7 @@ setup: setup-build setup-dev tidy ##@other Prepare project for development and b
generate: ##@other Regenerate assets and other auto-generated stuff
go generate ./static ./static/chat_db_migrations ./static/mailserver_db_migrations ./t
$(shell cd ./services/shhext/chat/protobuf && exec protoc --go_out=. ./*.proto)
$(shell cd ./messaging/chat/protobuf && exec protoc --go_out=. ./*.proto)
prepare-release: clean-release
mkdir -p $(RELEASE_DIR)

View File

@ -1 +1 @@
0.28.0-beta.0
0.29.0-beta.0

View File

@ -19,13 +19,13 @@ import (
"github.com/ethereum/go-ethereum/p2p/enode"
"github.com/status-im/status-go/account"
"github.com/status-im/status-go/mailserver/registry"
"github.com/status-im/status-go/messaging/chat/crypto"
"github.com/status-im/status-go/node"
"github.com/status-im/status-go/notifications/push/fcm"
"github.com/status-im/status-go/params"
"github.com/status-im/status-go/rpc"
"github.com/status-im/status-go/services/personal"
"github.com/status-im/status-go/services/rpcfilters"
"github.com/status-im/status-go/services/shhext/chat/crypto"
"github.com/status-im/status-go/services/subscriptions"
"github.com/status-im/status-go/services/typeddata"
"github.com/status-im/status-go/signal"

View File

@ -9,7 +9,7 @@ import (
"github.com/status-im/migrate/v4"
"github.com/status-im/migrate/v4/database/sqlcipher"
"github.com/status-im/migrate/v4/source/go_bindata"
"github.com/status-im/status-go/services/shhext/chat/db/migrations"
"github.com/status-im/status-go/messaging/chat/db/migrations"
)
const exportDB = "SELECT sqlcipher_export('newdb')"

View File

@ -12,9 +12,9 @@ import (
"github.com/ethereum/go-ethereum/log"
dr "github.com/status-im/doubleratchet"
"github.com/status-im/status-go/services/shhext/chat/crypto"
"github.com/status-im/status-go/services/shhext/chat/multidevice"
"github.com/status-im/status-go/services/shhext/chat/protobuf"
"github.com/status-im/status-go/messaging/chat/crypto"
"github.com/status-im/status-go/messaging/chat/multidevice"
"github.com/status-im/status-go/messaging/chat/protobuf"
)
var ErrSessionNotFound = errors.New("session not found")

View File

@ -8,8 +8,8 @@ import (
"os"
"testing"
"github.com/status-im/status-go/services/shhext/chat/multidevice"
"github.com/status-im/status-go/services/shhext/chat/sharedsecret"
"github.com/status-im/status-go/messaging/chat/multidevice"
"github.com/status-im/status-go/messaging/chat/sharedsecret"
)
const (

View File

@ -13,9 +13,9 @@ import (
"time"
"github.com/ethereum/go-ethereum/crypto"
"github.com/status-im/status-go/services/shhext/chat/multidevice"
"github.com/status-im/status-go/services/shhext/chat/protobuf"
"github.com/status-im/status-go/services/shhext/chat/sharedsecret"
"github.com/status-im/status-go/messaging/chat/multidevice"
"github.com/status-im/status-go/messaging/chat/protobuf"
"github.com/status-im/status-go/messaging/chat/sharedsecret"
"github.com/stretchr/testify/suite"
)

View File

@ -4,7 +4,7 @@ import (
"crypto/ecdsa"
"fmt"
"github.com/ethereum/go-ethereum/crypto"
"github.com/status-im/status-go/services/shhext/chat/protobuf"
"github.com/status-im/status-go/messaging/chat/protobuf"
)
type InstallationMetadata struct {

View File

@ -5,7 +5,7 @@ import (
"os"
"testing"
chatDB "github.com/status-im/status-go/services/shhext/chat/db"
chatDB "github.com/status-im/status-go/messaging/chat/db"
"github.com/stretchr/testify/suite"
)

View File

@ -4,8 +4,8 @@ import (
"crypto/ecdsa"
dr "github.com/status-im/doubleratchet"
"github.com/status-im/status-go/services/shhext/chat/multidevice"
"github.com/status-im/status-go/services/shhext/chat/protobuf"
"github.com/status-im/status-go/messaging/chat/multidevice"
"github.com/status-im/status-go/messaging/chat/protobuf"
)
// RatchetInfo holds the current ratchet state

View File

@ -5,9 +5,9 @@ import (
"errors"
"github.com/ethereum/go-ethereum/log"
"github.com/status-im/status-go/services/shhext/chat/multidevice"
"github.com/status-im/status-go/services/shhext/chat/protobuf"
"github.com/status-im/status-go/services/shhext/chat/sharedsecret"
"github.com/status-im/status-go/messaging/chat/multidevice"
"github.com/status-im/status-go/messaging/chat/protobuf"
"github.com/status-im/status-go/messaging/chat/sharedsecret"
)
const ProtocolVersion = 1

View File

@ -5,8 +5,8 @@ import (
"testing"
"github.com/ethereum/go-ethereum/crypto"
"github.com/status-im/status-go/services/shhext/chat/multidevice"
"github.com/status-im/status-go/services/shhext/chat/sharedsecret"
"github.com/status-im/status-go/messaging/chat/multidevice"
"github.com/status-im/status-go/messaging/chat/sharedsecret"
"github.com/stretchr/testify/suite"
)

View File

@ -6,7 +6,7 @@ import (
"testing"
"github.com/ethereum/go-ethereum/crypto"
chatDB "github.com/status-im/status-go/services/shhext/chat/db"
chatDB "github.com/status-im/status-go/messaging/chat/db"
"github.com/stretchr/testify/suite"
)

View File

@ -8,11 +8,11 @@ import (
"github.com/ethereum/go-ethereum/crypto"
dr "github.com/status-im/doubleratchet"
ecrypto "github.com/status-im/status-go/services/shhext/chat/crypto"
chatDB "github.com/status-im/status-go/services/shhext/chat/db"
"github.com/status-im/status-go/services/shhext/chat/multidevice"
"github.com/status-im/status-go/services/shhext/chat/protobuf"
"github.com/status-im/status-go/services/shhext/chat/sharedsecret"
ecrypto "github.com/status-im/status-go/messaging/chat/crypto"
chatDB "github.com/status-im/status-go/messaging/chat/db"
"github.com/status-im/status-go/messaging/chat/multidevice"
"github.com/status-im/status-go/messaging/chat/protobuf"
"github.com/status-im/status-go/messaging/chat/sharedsecret"
)
// A safe max number of rows

View File

@ -6,7 +6,7 @@ import (
"testing"
"github.com/ethereum/go-ethereum/crypto"
"github.com/status-im/status-go/services/shhext/chat/multidevice"
"github.com/status-im/status-go/messaging/chat/multidevice"
"github.com/stretchr/testify/suite"
)

View File

@ -9,7 +9,7 @@ import (
"github.com/ethereum/go-ethereum/crypto"
"github.com/ethereum/go-ethereum/crypto/ecies"
"github.com/status-im/status-go/services/shhext/chat/protobuf"
"github.com/status-im/status-go/messaging/chat/protobuf"
)
const (

View File

@ -6,7 +6,7 @@ import (
"github.com/ethereum/go-ethereum/crypto"
"github.com/ethereum/go-ethereum/crypto/ecies"
"github.com/status-im/status-go/services/shhext/chat/protobuf"
"github.com/status-im/status-go/messaging/chat/protobuf"
"github.com/stretchr/testify/require"
)

View File

@ -7,7 +7,7 @@ import (
"fmt"
"github.com/ethereum/go-ethereum/crypto"
"github.com/ethereum/go-ethereum/log"
"github.com/status-im/status-go/services/shhext/chat/sharedsecret"
"github.com/status-im/status-go/messaging/chat/sharedsecret"
whisper "github.com/status-im/whisper/whisperv6"
"math/big"
"sync"

View File

@ -8,8 +8,8 @@ import (
"testing"
"github.com/ethereum/go-ethereum/crypto"
chatDB "github.com/status-im/status-go/services/shhext/chat/db"
"github.com/status-im/status-go/services/shhext/chat/sharedsecret"
chatDB "github.com/status-im/status-go/messaging/chat/db"
"github.com/status-im/status-go/messaging/chat/sharedsecret"
whisper "github.com/status-im/whisper/whisperv6"
"github.com/stretchr/testify/suite"
)

View File

@ -9,13 +9,13 @@ import (
"github.com/ethereum/go-ethereum/crypto"
"github.com/ethereum/go-ethereum/log"
"github.com/golang/protobuf/proto"
"github.com/status-im/status-go/services/shhext/chat"
chatDB "github.com/status-im/status-go/services/shhext/chat/db"
"github.com/status-im/status-go/services/shhext/chat/multidevice"
"github.com/status-im/status-go/services/shhext/chat/protobuf"
"github.com/status-im/status-go/services/shhext/chat/sharedsecret"
"github.com/status-im/status-go/messaging/chat"
chatDB "github.com/status-im/status-go/messaging/chat/db"
"github.com/status-im/status-go/messaging/chat/multidevice"
"github.com/status-im/status-go/messaging/chat/protobuf"
"github.com/status-im/status-go/messaging/chat/sharedsecret"
"github.com/status-im/status-go/messaging/filter"
"github.com/status-im/status-go/services/shhext/dedup"
"github.com/status-im/status-go/services/shhext/filter"
"github.com/status-im/status-go/services/shhext/whisperutils"
"github.com/status-im/status-go/signal"
whisper "github.com/status-im/whisper/whisperv6"

View File

@ -9,8 +9,8 @@ import (
"github.com/ethereum/go-ethereum/common/hexutil"
"github.com/ethereum/go-ethereum/crypto"
"github.com/ethereum/go-ethereum/crypto/ecies"
"github.com/status-im/status-go/messaging/filter"
"github.com/status-im/status-go/services/shhext/dedup"
"github.com/status-im/status-go/services/shhext/filter"
"github.com/status-im/status-go/services/shhext/whisperutils"
whisper "github.com/status-im/whisper/whisperv6"
"github.com/stretchr/testify/suite"

View File

@ -17,10 +17,10 @@ import (
"github.com/status-im/status-go/db"
"github.com/status-im/status-go/mailserver"
"github.com/status-im/status-go/services/shhext/chat"
"github.com/status-im/status-go/services/shhext/chat/multidevice"
"github.com/status-im/status-go/messaging/chat"
"github.com/status-im/status-go/messaging/chat/multidevice"
"github.com/status-im/status-go/messaging/filter"
"github.com/status-im/status-go/services/shhext/dedup"
"github.com/status-im/status-go/services/shhext/filter"
"github.com/status-im/status-go/services/shhext/mailservers"
whisper "github.com/status-im/whisper/whisperv6"
)

View File

@ -13,11 +13,11 @@ import (
"github.com/ethereum/go-ethereum/p2p/enode"
"github.com/ethereum/go-ethereum/rpc"
"github.com/status-im/status-go/db"
"github.com/status-im/status-go/messaging/filter"
"github.com/status-im/status-go/messaging/publisher"
"github.com/status-im/status-go/params"
"github.com/status-im/status-go/services/shhext/dedup"
"github.com/status-im/status-go/services/shhext/filter"
"github.com/status-im/status-go/services/shhext/mailservers"
"github.com/status-im/status-go/services/shhext/publisher"
whisper "github.com/status-im/whisper/whisperv6"
"github.com/syndtr/goleveldb/leveldb"
)

View File

@ -1,4 +1,4 @@
// Package static embeds static (JS, HTML) resources right into the binaries
package static
//go:generate go-bindata -pkg migrations -o ../../services/shhext/chat/db/migrations/bindata.go .
//go:generate go-bindata -pkg migrations -o ../../messaging/chat/db/migrations/bindata.go .