Move top level packages to internal.

This commit is contained in:
Jakob Borg 2014-09-22 21:42:11 +02:00
parent fbdbd722b1
commit 14817e31f6
174 changed files with 252 additions and 254 deletions

View File

@ -233,11 +233,11 @@ func setBuildEnv() {
} }
func assets() { func assets() {
runPipe("auto/gui.files.go", "godep", "go", "run", "cmd/genassets/main.go", "gui") runPipe("internal/auto/gui.files.go", "godep", "go", "run", "cmd/genassets/main.go", "gui")
} }
func xdr() { func xdr() {
for _, f := range []string{"discover/packets", "files/leveldb", "protocol/message"} { for _, f := range []string{"internal/discover/packets", "internal/files/leveldb", "internal/protocol/message"} {
runPipe(f+"_xdr.go", "go", "run", "./Godeps/_workspace/src/github.com/calmh/xdr/cmd/genxdr/main.go", "--", f+".go") runPipe(f+"_xdr.go", "go", "run", "./Godeps/_workspace/src/github.com/calmh/xdr/cmd/genxdr/main.go", "--", f+".go")
} }
} }

View File

@ -10,8 +10,8 @@ import (
"log" "log"
"os" "os"
"github.com/syncthing/syncthing/files" "github.com/syncthing/syncthing/internal/files"
"github.com/syncthing/syncthing/protocol" "github.com/syncthing/syncthing/internal/protocol"
"github.com/syndtr/goleveldb/leveldb" "github.com/syndtr/goleveldb/leveldb"
) )

View File

@ -21,13 +21,13 @@ import (
"time" "time"
"code.google.com/p/go.crypto/bcrypt" "code.google.com/p/go.crypto/bcrypt"
"github.com/syncthing/syncthing/auto" "github.com/syncthing/syncthing/internal/auto"
"github.com/syncthing/syncthing/config" "github.com/syncthing/syncthing/internal/config"
"github.com/syncthing/syncthing/events" "github.com/syncthing/syncthing/internal/events"
"github.com/syncthing/syncthing/logger" "github.com/syncthing/syncthing/internal/logger"
"github.com/syncthing/syncthing/model" "github.com/syncthing/syncthing/internal/model"
"github.com/syncthing/syncthing/protocol" "github.com/syncthing/syncthing/internal/protocol"
"github.com/syncthing/syncthing/upgrade" "github.com/syncthing/syncthing/internal/upgrade"
"github.com/vitrun/qart/qr" "github.com/vitrun/qart/qr"
) )

View File

@ -14,7 +14,7 @@ import (
"time" "time"
"code.google.com/p/go.crypto/bcrypt" "code.google.com/p/go.crypto/bcrypt"
"github.com/syncthing/syncthing/config" "github.com/syncthing/syncthing/internal/config"
) )
var ( var (

View File

@ -16,7 +16,7 @@ import (
"sync" "sync"
"time" "time"
"github.com/syncthing/syncthing/osutil" "github.com/syncthing/syncthing/internal/osutil"
) )
var csrfTokens []string var csrfTokens []string

View File

@ -27,15 +27,15 @@ import (
"code.google.com/p/go.crypto/bcrypt" "code.google.com/p/go.crypto/bcrypt"
"github.com/juju/ratelimit" "github.com/juju/ratelimit"
"github.com/syncthing/syncthing/config" "github.com/syncthing/syncthing/internal/config"
"github.com/syncthing/syncthing/discover" "github.com/syncthing/syncthing/internal/discover"
"github.com/syncthing/syncthing/events" "github.com/syncthing/syncthing/internal/events"
"github.com/syncthing/syncthing/files" "github.com/syncthing/syncthing/internal/files"
"github.com/syncthing/syncthing/logger" "github.com/syncthing/syncthing/internal/logger"
"github.com/syncthing/syncthing/model" "github.com/syncthing/syncthing/internal/model"
"github.com/syncthing/syncthing/protocol" "github.com/syncthing/syncthing/internal/protocol"
"github.com/syncthing/syncthing/upgrade" "github.com/syncthing/syncthing/internal/upgrade"
"github.com/syncthing/syncthing/upnp" "github.com/syncthing/syncthing/internal/upnp"
"github.com/syndtr/goleveldb/leveldb" "github.com/syndtr/goleveldb/leveldb"
"github.com/syndtr/goleveldb/leveldb/opt" "github.com/syndtr/goleveldb/leveldb/opt"
) )

View File

@ -15,7 +15,7 @@ import (
"strings" "strings"
"time" "time"
"github.com/syncthing/syncthing/model" "github.com/syncthing/syncthing/internal/model"
) )
// Current version number of the usage report, for acceptance purposes. If // Current version number of the usage report, for acceptance purposes. If

View File

@ -8,7 +8,7 @@ import (
"bytes" "bytes"
"testing" "testing"
"github.com/syncthing/syncthing/auto" "github.com/syncthing/syncthing/internal/auto"
) )
func TestAssets(t *testing.T) { func TestAssets(t *testing.T) {

View File

@ -8,7 +8,7 @@ import (
"os" "os"
"strings" "strings"
"github.com/syncthing/syncthing/logger" "github.com/syncthing/syncthing/internal/logger"
) )
var ( var (

View File

@ -14,10 +14,10 @@ import (
"strconv" "strconv"
"code.google.com/p/go.crypto/bcrypt" "code.google.com/p/go.crypto/bcrypt"
"github.com/syncthing/syncthing/events" "github.com/syncthing/syncthing/internal/events"
"github.com/syncthing/syncthing/logger" "github.com/syncthing/syncthing/internal/logger"
"github.com/syncthing/syncthing/osutil" "github.com/syncthing/syncthing/internal/osutil"
"github.com/syncthing/syncthing/protocol" "github.com/syncthing/syncthing/internal/protocol"
) )
var l = logger.DefaultLogger var l = logger.DefaultLogger

View File

@ -9,7 +9,7 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/syncthing/syncthing/protocol" "github.com/syncthing/syncthing/internal/protocol"
) )
var node1, node2, node3, node4 protocol.NodeID var node1, node2, node3, node4 protocol.NodeID

View File

@ -136,4 +136,3 @@ This is the XDR encoding of:
unsigned int MagicNumber; unsigned int MagicNumber;
string NodeID<>; string NodeID<>;
} }

View File

@ -8,7 +8,7 @@ import (
"os" "os"
"strings" "strings"
"github.com/syncthing/syncthing/logger" "github.com/syncthing/syncthing/internal/logger"
) )
var ( var (

View File

@ -14,9 +14,9 @@ import (
"sync" "sync"
"time" "time"
"github.com/syncthing/syncthing/beacon" "github.com/syncthing/syncthing/internal/beacon"
"github.com/syncthing/syncthing/events" "github.com/syncthing/syncthing/internal/events"
"github.com/syncthing/syncthing/protocol" "github.com/syncthing/syncthing/internal/protocol"
) )
type Discoverer struct { type Discoverer struct {

View File

@ -8,7 +8,7 @@ import (
"os" "os"
"strings" "strings"
"github.com/syncthing/syncthing/logger" "github.com/syncthing/syncthing/internal/logger"
) )
var ( var (

View File

@ -9,7 +9,7 @@ import (
"testing" "testing"
"time" "time"
"github.com/syncthing/syncthing/events" "github.com/syncthing/syncthing/internal/events"
) )
var timeout = 100 * time.Millisecond var timeout = 100 * time.Millisecond

View File

@ -8,7 +8,7 @@ import (
"os" "os"
"strings" "strings"
"github.com/syncthing/syncthing/logger" "github.com/syncthing/syncthing/internal/logger"
) )
var ( var (

View File

@ -10,8 +10,8 @@ import (
"sort" "sort"
"sync" "sync"
"github.com/syncthing/syncthing/lamport" "github.com/syncthing/syncthing/internal/lamport"
"github.com/syncthing/syncthing/protocol" "github.com/syncthing/syncthing/internal/protocol"
"github.com/syndtr/goleveldb/leveldb" "github.com/syndtr/goleveldb/leveldb"
"github.com/syndtr/goleveldb/leveldb/iterator" "github.com/syndtr/goleveldb/leveldb/iterator"
"github.com/syndtr/goleveldb/leveldb/opt" "github.com/syndtr/goleveldb/leveldb/opt"

View File

@ -13,8 +13,8 @@ package files
import ( import (
"sync" "sync"
"github.com/syncthing/syncthing/lamport" "github.com/syncthing/syncthing/internal/lamport"
"github.com/syncthing/syncthing/protocol" "github.com/syncthing/syncthing/internal/protocol"
"github.com/syndtr/goleveldb/leveldb" "github.com/syndtr/goleveldb/leveldb"
) )

View File

@ -11,9 +11,9 @@ import (
"sort" "sort"
"testing" "testing"
"github.com/syncthing/syncthing/files" "github.com/syncthing/syncthing/internal/files"
"github.com/syncthing/syncthing/lamport" "github.com/syncthing/syncthing/internal/lamport"
"github.com/syncthing/syncthing/protocol" "github.com/syncthing/syncthing/internal/protocol"
"github.com/syndtr/goleveldb/leveldb" "github.com/syndtr/goleveldb/leveldb"
"github.com/syndtr/goleveldb/leveldb/storage" "github.com/syndtr/goleveldb/leveldb/storage"
) )

View File

@ -13,7 +13,7 @@ import (
"regexp" "regexp"
"strings" "strings"
"github.com/syncthing/syncthing/fnmatch" "github.com/syncthing/syncthing/internal/fnmatch"
) )
type Pattern struct { type Pattern struct {

View File

@ -10,7 +10,7 @@ import (
"runtime" "runtime"
"testing" "testing"
"github.com/syncthing/syncthing/ignore" "github.com/syncthing/syncthing/internal/ignore"
) )
func TestIgnore(t *testing.T) { func TestIgnore(t *testing.T) {

View File

@ -7,7 +7,7 @@ package luhn_test
import ( import (
"testing" "testing"
"github.com/syncthing/syncthing/luhn" "github.com/syncthing/syncthing/internal/luhn"
) )
func TestGenerate(t *testing.T) { func TestGenerate(t *testing.T) {

View File

@ -4,7 +4,7 @@
package model package model
import "github.com/syncthing/syncthing/protocol" import "github.com/syncthing/syncthing/internal/protocol"
type bqAdd struct { type bqAdd struct {
file protocol.FileInfo file protocol.FileInfo

View File

@ -8,7 +8,7 @@ import (
"os" "os"
"strings" "strings"
"github.com/syncthing/syncthing/logger" "github.com/syncthing/syncthing/internal/logger"
) )
var ( var (

View File

@ -19,15 +19,15 @@ import (
"sync" "sync"
"time" "time"
"github.com/syncthing/syncthing/config" "github.com/syncthing/syncthing/internal/config"
"github.com/syncthing/syncthing/events" "github.com/syncthing/syncthing/internal/events"
"github.com/syncthing/syncthing/files" "github.com/syncthing/syncthing/internal/files"
"github.com/syncthing/syncthing/ignore" "github.com/syncthing/syncthing/internal/ignore"
"github.com/syncthing/syncthing/lamport" "github.com/syncthing/syncthing/internal/lamport"
"github.com/syncthing/syncthing/osutil" "github.com/syncthing/syncthing/internal/osutil"
"github.com/syncthing/syncthing/protocol" "github.com/syncthing/syncthing/internal/protocol"
"github.com/syncthing/syncthing/scanner" "github.com/syncthing/syncthing/internal/scanner"
"github.com/syncthing/syncthing/stats" "github.com/syncthing/syncthing/internal/stats"
"github.com/syndtr/goleveldb/leveldb" "github.com/syndtr/goleveldb/leveldb"
) )

View File

@ -11,8 +11,8 @@ import (
"testing" "testing"
"time" "time"
"github.com/syncthing/syncthing/config" "github.com/syncthing/syncthing/internal/config"
"github.com/syncthing/syncthing/protocol" "github.com/syncthing/syncthing/internal/protocol"
"github.com/syndtr/goleveldb/leveldb" "github.com/syndtr/goleveldb/leveldb"
"github.com/syndtr/goleveldb/leveldb/storage" "github.com/syndtr/goleveldb/leveldb/storage"
) )

View File

@ -32,12 +32,12 @@ import (
"path/filepath" "path/filepath"
"time" "time"
"github.com/syncthing/syncthing/config" "github.com/syncthing/syncthing/internal/config"
"github.com/syncthing/syncthing/events" "github.com/syncthing/syncthing/internal/events"
"github.com/syncthing/syncthing/osutil" "github.com/syncthing/syncthing/internal/osutil"
"github.com/syncthing/syncthing/protocol" "github.com/syncthing/syncthing/internal/protocol"
"github.com/syncthing/syncthing/scanner" "github.com/syncthing/syncthing/internal/scanner"
"github.com/syncthing/syncthing/versioner" "github.com/syncthing/syncthing/internal/versioner"
) )
type requestResult struct { type requestResult struct {

View File

@ -8,7 +8,7 @@ import (
"os" "os"
"strings" "strings"
"github.com/syncthing/syncthing/logger" "github.com/syncthing/syncthing/internal/logger"
) )
var ( var (

View File

@ -13,7 +13,7 @@ import (
"regexp" "regexp"
"strings" "strings"
"github.com/syncthing/syncthing/luhn" "github.com/syncthing/syncthing/internal/luhn"
) )
type NodeID [32]byte type NodeID [32]byte

View File

@ -9,7 +9,7 @@ import (
"path/filepath" "path/filepath"
"sync" "sync"
"github.com/syncthing/syncthing/protocol" "github.com/syncthing/syncthing/internal/protocol"
) )
// The parallell hasher reads FileInfo structures from the inbox, hashes the // The parallell hasher reads FileInfo structures from the inbox, hashes the

View File

@ -9,7 +9,7 @@ import (
"crypto/sha256" "crypto/sha256"
"io" "io"
"github.com/syncthing/syncthing/protocol" "github.com/syncthing/syncthing/internal/protocol"
) )
const StandardBlockSize = 128 * 1024 const StandardBlockSize = 128 * 1024

View File

@ -9,7 +9,7 @@ import (
"fmt" "fmt"
"testing" "testing"
"github.com/syncthing/syncthing/protocol" "github.com/syncthing/syncthing/internal/protocol"
) )
var blocksTestData = []struct { var blocksTestData = []struct {

View File

@ -8,7 +8,7 @@ import (
"os" "os"
"strings" "strings"
"github.com/syncthing/syncthing/logger" "github.com/syncthing/syncthing/internal/logger"
) )
var ( var (

Some files were not shown because too many files have changed in this diff Show More