diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ca6a04c..2586c48 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -14,7 +14,7 @@ repos: - id: go-imports-repo args: - "-local" - - "github.com/benbjohnson/litestrem" + - "github.com/benbjohnson/litestream" - "-w" - id: go-vet-repo-mod - id: go-staticcheck-repo-mod diff --git a/abs/replica_client.go b/abs/replica_client.go index feaef16..52e7984 100644 --- a/abs/replica_client.go +++ b/abs/replica_client.go @@ -11,10 +11,11 @@ import ( "time" "github.com/Azure/azure-storage-blob-go/azblob" - "github.com/benbjohnson/litestream" - "github.com/benbjohnson/litestream/internal" "github.com/superfly/ltx" "golang.org/x/sync/errgroup" + + "github.com/benbjohnson/litestream" + "github.com/benbjohnson/litestream/internal" ) // ReplicaClientType is the client type for this package. diff --git a/cmd/litestream/main.go b/cmd/litestream/main.go index 257f47d..6e58c37 100644 --- a/cmd/litestream/main.go +++ b/cmd/litestream/main.go @@ -16,6 +16,10 @@ import ( "time" "filippo.io/age" + _ "github.com/mattn/go-sqlite3" + "github.com/superfly/ltx" + "gopkg.in/yaml.v2" + "github.com/benbjohnson/litestream" "github.com/benbjohnson/litestream/abs" "github.com/benbjohnson/litestream/file" @@ -23,9 +27,6 @@ import ( "github.com/benbjohnson/litestream/internal" "github.com/benbjohnson/litestream/s3" "github.com/benbjohnson/litestream/sftp" - _ "github.com/mattn/go-sqlite3" - "github.com/superfly/ltx" - "gopkg.in/yaml.v2" ) // Build information. diff --git a/cmd/litestream/replicate.go b/cmd/litestream/replicate.go index b179d34..92fdf3c 100644 --- a/cmd/litestream/replicate.go +++ b/cmd/litestream/replicate.go @@ -11,14 +11,15 @@ import ( "os" "os/exec" + "github.com/mattn/go-shellwords" + "github.com/prometheus/client_golang/prometheus/promhttp" + "github.com/benbjohnson/litestream" "github.com/benbjohnson/litestream/abs" "github.com/benbjohnson/litestream/file" "github.com/benbjohnson/litestream/gcs" "github.com/benbjohnson/litestream/s3" "github.com/benbjohnson/litestream/sftp" - "github.com/mattn/go-shellwords" - "github.com/prometheus/client_golang/prometheus/promhttp" ) // ReplicateCommand represents a command that continuously replicates SQLite databases. diff --git a/db.go b/db.go index 4480459..1dc968f 100644 --- a/db.go +++ b/db.go @@ -17,10 +17,11 @@ import ( "sync" "time" - "github.com/benbjohnson/litestream/internal" "github.com/prometheus/client_golang/prometheus" "github.com/prometheus/client_golang/prometheus/promauto" "github.com/superfly/ltx" + + "github.com/benbjohnson/litestream/internal" ) // Default DB settings. diff --git a/db_test.go b/db_test.go index 53a47a1..5de27c7 100644 --- a/db_test.go +++ b/db_test.go @@ -12,9 +12,10 @@ import ( "testing" "time" + "github.com/superfly/ltx" + "github.com/benbjohnson/litestream" "github.com/benbjohnson/litestream/internal" - "github.com/superfly/ltx" ) var logLevel = flag.String("log.level", "debug", "") diff --git a/file/replica_client.go b/file/replica_client.go index 8f5cff6..828e99d 100644 --- a/file/replica_client.go +++ b/file/replica_client.go @@ -6,9 +6,10 @@ import ( "os" "path/filepath" + "github.com/superfly/ltx" + "github.com/benbjohnson/litestream" "github.com/benbjohnson/litestream/internal" - "github.com/superfly/ltx" ) // ReplicaClientType is the client type for this package. diff --git a/gcs/replica_client.go b/gcs/replica_client.go index b8289dd..11a503c 100644 --- a/gcs/replica_client.go +++ b/gcs/replica_client.go @@ -10,10 +10,11 @@ import ( "time" "cloud.google.com/go/storage" - "github.com/benbjohnson/litestream" - "github.com/benbjohnson/litestream/internal" "github.com/superfly/ltx" "google.golang.org/api/iterator" + + "github.com/benbjohnson/litestream" + "github.com/benbjohnson/litestream/internal" ) // ReplicaClientType is the client type for this package. diff --git a/litestream_test.go b/litestream_test.go index af66268..356f69c 100644 --- a/litestream_test.go +++ b/litestream_test.go @@ -5,9 +5,10 @@ import ( "encoding/hex" "testing" - "github.com/benbjohnson/litestream" _ "github.com/mattn/go-sqlite3" "github.com/superfly/ltx" + + "github.com/benbjohnson/litestream" ) func TestChecksum(t *testing.T) { diff --git a/mock/replica_client.go b/mock/replica_client.go index 2716897..569e7f2 100644 --- a/mock/replica_client.go +++ b/mock/replica_client.go @@ -4,8 +4,9 @@ import ( "context" "io" - "github.com/benbjohnson/litestream" "github.com/superfly/ltx" + + "github.com/benbjohnson/litestream" ) var _ litestream.ReplicaClient = (*ReplicaClient)(nil) diff --git a/replica_client_test.go b/replica_client_test.go index fa73e51..e9002c6 100644 --- a/replica_client_test.go +++ b/replica_client_test.go @@ -12,13 +12,14 @@ import ( "testing" "time" + "github.com/superfly/ltx" + "github.com/benbjohnson/litestream" "github.com/benbjohnson/litestream/abs" "github.com/benbjohnson/litestream/file" "github.com/benbjohnson/litestream/gcs" "github.com/benbjohnson/litestream/s3" "github.com/benbjohnson/litestream/sftp" - "github.com/superfly/ltx" ) var ( diff --git a/replica_test.go b/replica_test.go index f185d30..da89415 100644 --- a/replica_test.go +++ b/replica_test.go @@ -5,10 +5,11 @@ import ( "testing" "time" + "github.com/superfly/ltx" + "github.com/benbjohnson/litestream" "github.com/benbjohnson/litestream/file" "github.com/benbjohnson/litestream/mock" - "github.com/superfly/ltx" ) func TestReplica_Sync(t *testing.T) { diff --git a/s3/replica_client.go b/s3/replica_client.go index 4c866aa..2900e62 100644 --- a/s3/replica_client.go +++ b/s3/replica_client.go @@ -19,10 +19,11 @@ import ( "github.com/aws/aws-sdk-go/aws/session" "github.com/aws/aws-sdk-go/service/s3" "github.com/aws/aws-sdk-go/service/s3/s3manager" - "github.com/benbjohnson/litestream" - "github.com/benbjohnson/litestream/internal" "github.com/superfly/ltx" "golang.org/x/sync/errgroup" + + "github.com/benbjohnson/litestream" + "github.com/benbjohnson/litestream/internal" ) // ReplicaClientType is the client type for this package. diff --git a/sftp/replica_client.go b/sftp/replica_client.go index 0211980..1c38248 100644 --- a/sftp/replica_client.go +++ b/sftp/replica_client.go @@ -11,11 +11,12 @@ import ( "sync" "time" - "github.com/benbjohnson/litestream" - "github.com/benbjohnson/litestream/internal" "github.com/pkg/sftp" "github.com/superfly/ltx" "golang.org/x/crypto/ssh" + + "github.com/benbjohnson/litestream" + "github.com/benbjohnson/litestream/internal" ) // ReplicaClientType is the client type for this package.