build: fixup code formatting after goimports change

This commit is contained in:
Nick Craig-Wood 2018-10-13 14:41:15 +01:00
parent bb2e361004
commit ade252f13b
17 changed files with 26 additions and 49 deletions

View file

@ -4,29 +4,25 @@ package cache_test
import ( import (
"bytes" "bytes"
"encoding/base64"
"encoding/json"
goflag "flag"
"fmt"
"io" "io"
"io/ioutil" "io/ioutil"
"log" "log"
"math/rand" "math/rand"
"net/http"
"os" "os"
"path" "path"
"path/filepath" "path/filepath"
"runtime" "runtime"
"runtime/debug"
"strconv" "strconv"
"strings" "strings"
"testing" "testing"
"time" "time"
"github.com/pkg/errors"
"encoding/base64"
goflag "flag"
"fmt"
"runtime/debug"
"encoding/json"
"net/http"
"github.com/ncw/rclone/backend/cache" "github.com/ncw/rclone/backend/cache"
"github.com/ncw/rclone/backend/crypt" "github.com/ncw/rclone/backend/crypt"
_ "github.com/ncw/rclone/backend/drive" _ "github.com/ncw/rclone/backend/drive"
@ -40,6 +36,7 @@ import (
"github.com/ncw/rclone/fstest" "github.com/ncw/rclone/fstest"
"github.com/ncw/rclone/vfs" "github.com/ncw/rclone/vfs"
"github.com/ncw/rclone/vfs/vfsflags" "github.com/ncw/rclone/vfs/vfsflags"
"github.com/pkg/errors"
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
) )

View file

@ -3,6 +3,7 @@
package cache_test package cache_test
import ( import (
"fmt"
"math/rand" "math/rand"
"os" "os"
"path" "path"
@ -10,8 +11,6 @@ import (
"testing" "testing"
"time" "time"
"fmt"
"github.com/ncw/rclone/backend/cache" "github.com/ncw/rclone/backend/cache"
_ "github.com/ncw/rclone/backend/drive" _ "github.com/ncw/rclone/backend/drive"
"github.com/ncw/rclone/fs" "github.com/ncw/rclone/fs"

View file

@ -3,9 +3,8 @@
package cache package cache
import ( import (
"time"
"path" "path"
"time"
"github.com/ncw/rclone/fs" "github.com/ncw/rclone/fs"
) )

View file

@ -5,12 +5,11 @@ package cache
import ( import (
"fmt" "fmt"
"io" "io"
"sync"
"time"
"path" "path"
"runtime" "runtime"
"strings" "strings"
"sync"
"time"
"github.com/ncw/rclone/fs" "github.com/ncw/rclone/fs"
"github.com/ncw/rclone/fs/operations" "github.com/ncw/rclone/fs/operations"

View file

@ -3,18 +3,16 @@
package cache package cache
import ( import (
"bytes"
"crypto/tls" "crypto/tls"
"encoding/json" "encoding/json"
"fmt" "fmt"
"io/ioutil"
"net/http" "net/http"
"net/url" "net/url"
"strings" "strings"
"time"
"sync" "sync"
"time"
"bytes"
"io/ioutil"
"github.com/ncw/rclone/fs" "github.com/ncw/rclone/fs"
"github.com/patrickmn/go-cache" "github.com/patrickmn/go-cache"

View file

@ -3,20 +3,17 @@
package cache package cache
import ( import (
"time"
"bytes" "bytes"
"encoding/binary" "encoding/binary"
"encoding/json" "encoding/json"
"fmt"
"io/ioutil"
"os" "os"
"path" "path"
"strconv" "strconv"
"strings" "strings"
"sync" "sync"
"time"
"io/ioutil"
"fmt"
bolt "github.com/coreos/bbolt" bolt "github.com/coreos/bbolt"
"github.com/ncw/rclone/fs" "github.com/ncw/rclone/fs"

View file

@ -17,11 +17,9 @@ import (
"github.com/ncw/rclone/fs" "github.com/ncw/rclone/fs"
"github.com/ncw/rclone/fs/accounting" "github.com/ncw/rclone/fs/accounting"
"github.com/pkg/errors" "github.com/pkg/errors"
"github.com/rfjakob/eme"
"golang.org/x/crypto/nacl/secretbox" "golang.org/x/crypto/nacl/secretbox"
"golang.org/x/crypto/scrypt" "golang.org/x/crypto/scrypt"
"github.com/rfjakob/eme"
) )
// Constants // Constants

View file

@ -20,10 +20,6 @@ import (
"sync" "sync"
"time" "time"
"github.com/pkg/errors"
"github.com/spf13/cobra"
"github.com/spf13/pflag"
"github.com/ncw/rclone/fs" "github.com/ncw/rclone/fs"
"github.com/ncw/rclone/fs/accounting" "github.com/ncw/rclone/fs/accounting"
"github.com/ncw/rclone/fs/config/configflags" "github.com/ncw/rclone/fs/config/configflags"
@ -36,6 +32,9 @@ import (
"github.com/ncw/rclone/fs/rc" "github.com/ncw/rclone/fs/rc"
"github.com/ncw/rclone/fs/rc/rcflags" "github.com/ncw/rclone/fs/rc/rcflags"
"github.com/ncw/rclone/lib/atexit" "github.com/ncw/rclone/lib/atexit"
"github.com/pkg/errors"
"github.com/spf13/cobra"
"github.com/spf13/pflag"
) )
// Globals // Globals

View file

@ -3,7 +3,6 @@ package deletefile
import ( import (
"github.com/ncw/rclone/cmd" "github.com/ncw/rclone/cmd"
"github.com/ncw/rclone/fs/operations" "github.com/ncw/rclone/fs/operations"
"github.com/pkg/errors" "github.com/pkg/errors"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )

View file

@ -4,13 +4,12 @@ import (
"bytes" "bytes"
"testing" "testing"
_ "github.com/ncw/rclone/backend/local"
"github.com/ncw/rclone/fs" "github.com/ncw/rclone/fs"
"github.com/ncw/rclone/fs/list" "github.com/ncw/rclone/fs/list"
"github.com/ncw/rclone/fstest" "github.com/ncw/rclone/fstest"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
_ "github.com/ncw/rclone/backend/local"
) )
func TestDefaultLsf(t *testing.T) { func TestDefaultLsf(t *testing.T) {

View file

@ -12,7 +12,6 @@ import (
"regexp" "regexp"
"strconv" "strconv"
"strings" "strings"
"time" "time"
"github.com/ncw/rclone/cmd" "github.com/ncw/rclone/cmd"

View file

@ -14,7 +14,6 @@ import (
"github.com/ncw/rclone/vfs/vfsflags" "github.com/ncw/rclone/vfs/vfsflags"
"github.com/spf13/cobra" "github.com/spf13/cobra"
"golang.org/x/net/context" // switch to "context" when we stop supporting go1.8 "golang.org/x/net/context" // switch to "context" when we stop supporting go1.8
"golang.org/x/net/webdav" "golang.org/x/net/webdav"
) )

View file

@ -4,11 +4,10 @@ import (
"testing" "testing"
"time" "time"
_ "github.com/ncw/rclone/backend/local"
"github.com/ncw/rclone/fs" "github.com/ncw/rclone/fs"
"github.com/ncw/rclone/fstest" "github.com/ncw/rclone/fstest"
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
_ "github.com/ncw/rclone/backend/local"
) )
var ( var (

View file

@ -5,12 +5,11 @@ import (
"testing" "testing"
"github.com/a8m/tree" "github.com/a8m/tree"
_ "github.com/ncw/rclone/backend/local"
"github.com/ncw/rclone/fs" "github.com/ncw/rclone/fs"
"github.com/ncw/rclone/fstest" "github.com/ncw/rclone/fstest"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
_ "github.com/ncw/rclone/backend/local"
) )
func TestTree(t *testing.T) { func TestTree(t *testing.T) {

View file

@ -9,7 +9,6 @@ import (
"os" "os"
"github.com/ncw/rclone/fs/config" "github.com/ncw/rclone/fs/config"
"golang.org/x/sys/unix" "golang.org/x/sys/unix"
) )

View file

@ -12,7 +12,6 @@ import (
"io" "io"
"net/http" "net/http"
_ "net/http/pprof" // install the pprof http handlers _ "net/http/pprof" // install the pprof http handlers
"strings" "strings"
"github.com/ncw/rclone/cmd/serve/httplib" "github.com/ncw/rclone/cmd/serve/httplib"

View file

@ -4,9 +4,8 @@
package main package main
import ( import (
"github.com/ncw/rclone/cmd"
_ "github.com/ncw/rclone/backend/all" // import all backends _ "github.com/ncw/rclone/backend/all" // import all backends
"github.com/ncw/rclone/cmd"
_ "github.com/ncw/rclone/cmd/all" // import all commands _ "github.com/ncw/rclone/cmd/all" // import all commands
) )