Skip to content

Commit acd6d6f

Browse files
committed
move everything out of internal
1 parent e2c0ee8 commit acd6d6f

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

50 files changed

+138
-139
lines changed

BUILD

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ go_library(
2626
visibility = ["//visibility:private"],
2727
deps = [
2828
"//internal/cli",
29-
"//internal/program",
29+
"//program",
3030
"@com_github_google_logger//:logger",
3131
],
3232
)

internal/bindetector/BUILD.bazel renamed to bindetector/BUILD.bazel

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ go_library(
77
"bindetector_unix.go",
88
"bindetector_windows.go",
99
],
10-
importpath = "github.com/discentem/cavorite/internal/bindetector",
10+
importpath = "github.com/discentem/cavorite/bindetector",
1111
visibility = ["//:__subpackages__"],
1212
deps = ["@com_github_google_logger//:logger"],
1313
)
File renamed without changes.

internal/config/BUILD.bazel renamed to config/BUILD.bazel

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@ go_library(
66
"config.go",
77
"load.go",
88
],
9-
importpath = "github.com/discentem/cavorite/internal/config",
9+
importpath = "github.com/discentem/cavorite/config",
1010
visibility = ["//:__subpackages__"],
1111
deps = [
12-
"//internal/stores",
12+
"//stores",
1313
"@com_github_google_logger//:logger",
1414
"@com_github_mitchellh_go_homedir//:go-homedir",
1515
"@com_github_spf13_afero//:afero",
@@ -25,8 +25,8 @@ go_test(
2525
],
2626
embed = [":config"],
2727
deps = [
28-
"//internal/stores",
29-
"//internal/testutils",
28+
"//stores",
29+
"//testutils",
3030
"@com_github_spf13_afero//:afero",
3131
"@com_github_stretchr_testify//assert",
3232
"@com_github_stretchr_testify//require",

internal/config/config.go renamed to config/config.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import (
88
"os"
99
"path/filepath"
1010

11-
"github.com/discentem/cavorite/internal/stores"
11+
"github.com/discentem/cavorite/stores"
1212
"github.com/google/logger"
1313
"github.com/mitchellh/go-homedir"
1414
"github.com/spf13/afero"

internal/config/config_test.go renamed to config/config_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import (
55
"errors"
66
"testing"
77

8-
"github.com/discentem/cavorite/internal/stores"
8+
"github.com/discentem/cavorite/stores"
99
"github.com/spf13/afero"
1010
"github.com/stretchr/testify/assert"
1111
)

internal/config/load.go renamed to config/load.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package config
22

33
import (
4-
"github.com/discentem/cavorite/internal/stores"
4+
"github.com/discentem/cavorite/stores"
55
"github.com/spf13/afero"
66
"github.com/spf13/viper"
77
)

internal/config/load_test.go renamed to config/load_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ package config
33
import (
44
"testing"
55

6-
"github.com/discentem/cavorite/internal/stores"
7-
"github.com/discentem/cavorite/internal/testutils"
6+
"github.com/discentem/cavorite/stores"
7+
"github.com/discentem/cavorite/testutils"
88
"github.com/spf13/afero"
99
"github.com/stretchr/testify/assert"
1010
"github.com/stretchr/testify/require"

internal/exec/BUILD.bazel renamed to exec/BUILD.bazel

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@ load("@io_bazel_rules_go//go:def.bzl", "go_library")
33
go_library(
44
name = "exec",
55
srcs = ["exec.go"],
6-
importpath = "github.com/discentem/cavorite/internal/exec",
6+
importpath = "github.com/discentem/cavorite/exec",
77
visibility = ["//:__subpackages__"],
88
)
File renamed without changes.

internal/fileutils/BUILD.bazel renamed to fileutils/BUILD.bazel

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ load("@io_bazel_rules_go//go:def.bzl", "go_library")
33
go_library(
44
name = "fileutils",
55
srcs = ["fileutils.go"],
6-
importpath = "github.com/discentem/cavorite/internal/fileutils",
6+
importpath = "github.com/discentem/cavorite/fileutils",
77
visibility = ["//:__subpackages__"],
88
deps = ["@com_github_spf13_afero//:afero"],
99
)
File renamed without changes.

internal/cli/BUILD.bazel

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,10 @@ go_library(
1212
importpath = "github.com/discentem/cavorite/internal/cli",
1313
visibility = ["//:__subpackages__"],
1414
deps = [
15-
"//internal/config",
16-
"//internal/metadata",
17-
"//internal/program",
18-
"//internal/stores",
15+
"//config",
16+
"//metadata",
17+
"//program",
18+
"//stores",
1919
"@com_github_azure_azure_sdk_for_go_sdk_storage_azblob//:azblob",
2020
"@com_github_google_logger//:logger",
2121
"@com_github_hashicorp_go_multierror//:go-multierror",
@@ -36,10 +36,10 @@ go_test(
3636
],
3737
embed = [":cli"],
3838
deps = [
39-
"//internal/config",
40-
"//internal/metadata",
41-
"//internal/stores",
42-
"//internal/testutils",
39+
"//config",
40+
"//metadata",
41+
"//stores",
42+
"//testutils",
4343
"@com_github_gonuts_go_shellquote//:go-shellquote",
4444
"@com_github_spf13_afero//:afero",
4545
"@com_github_stretchr_testify//assert",

internal/cli/helpers.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ import (
1212
"github.com/google/logger"
1313
"github.com/spf13/afero"
1414

15-
"github.com/discentem/cavorite/internal/config"
16-
"github.com/discentem/cavorite/internal/stores"
15+
"github.com/discentem/cavorite/config"
16+
"github.com/discentem/cavorite/stores"
1717
)
1818

1919
func rootOfSourceRepo() (*string, error) {

internal/cli/helpers_test.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@ import (
66
"os"
77
"testing"
88

9-
"github.com/discentem/cavorite/internal/config"
10-
"github.com/discentem/cavorite/internal/metadata"
11-
"github.com/discentem/cavorite/internal/stores"
9+
"github.com/discentem/cavorite/config"
10+
"github.com/discentem/cavorite/metadata"
11+
"github.com/discentem/cavorite/stores"
1212
"github.com/spf13/afero"
1313
"github.com/stretchr/testify/assert"
1414
)

internal/cli/init.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@ import (
88
"github.com/spf13/cobra"
99
"github.com/spf13/viper"
1010

11-
"github.com/discentem/cavorite/internal/config"
12-
"github.com/discentem/cavorite/internal/program"
13-
"github.com/discentem/cavorite/internal/stores"
11+
"github.com/discentem/cavorite/config"
12+
"github.com/discentem/cavorite/program"
13+
"github.com/discentem/cavorite/stores"
1414
)
1515

1616
func initCmd() *cobra.Command {

internal/cli/retrieve.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ import (
44
"errors"
55
"fmt"
66

7-
"github.com/discentem/cavorite/internal/config"
8-
"github.com/discentem/cavorite/internal/program"
7+
"github.com/discentem/cavorite/config"
8+
"github.com/discentem/cavorite/program"
99
"github.com/google/logger"
1010
"github.com/spf13/afero"
1111
"github.com/spf13/cobra"

internal/cli/root.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@ import (
88
"github.com/spf13/cobra"
99
"github.com/spf13/viper"
1010

11-
"github.com/discentem/cavorite/internal/metadata"
12-
"github.com/discentem/cavorite/internal/program"
13-
"github.com/discentem/cavorite/internal/stores"
11+
"github.com/discentem/cavorite/metadata"
12+
"github.com/discentem/cavorite/program"
13+
"github.com/discentem/cavorite/stores"
1414
)
1515

1616
var (

internal/cli/upload.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ import (
1111
"github.com/spf13/afero"
1212
"github.com/spf13/cobra"
1313

14-
"github.com/discentem/cavorite/internal/config"
15-
"github.com/discentem/cavorite/internal/metadata"
16-
"github.com/discentem/cavorite/internal/program"
17-
"github.com/discentem/cavorite/internal/stores"
14+
"github.com/discentem/cavorite/config"
15+
"github.com/discentem/cavorite/metadata"
16+
"github.com/discentem/cavorite/program"
17+
"github.com/discentem/cavorite/stores"
1818
)
1919

2020
func uploadCmd() *cobra.Command {

internal/cli/upload_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ import (
66
"testing"
77
"time"
88

9-
"github.com/discentem/cavorite/internal/stores"
10-
"github.com/discentem/cavorite/internal/testutils"
9+
"github.com/discentem/cavorite/stores"
10+
"github.com/discentem/cavorite/testutils"
1111
"github.com/gonuts/go-shellquote"
1212
"github.com/spf13/afero"
1313
"github.com/stretchr/testify/assert"

main.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import (
88
"github.com/google/logger"
99

1010
"github.com/discentem/cavorite/internal/cli"
11-
"github.com/discentem/cavorite/internal/program"
11+
"github.com/discentem/cavorite/program"
1212
)
1313

1414
func main() {

internal/metadata/BUILD.bazel renamed to metadata/BUILD.bazel

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
33
go_library(
44
name = "metadata",
55
srcs = ["metadata.go"],
6-
importpath = "github.com/discentem/cavorite/internal/metadata",
6+
importpath = "github.com/discentem/cavorite/metadata",
77
visibility = ["//:__subpackages__"],
88
deps = [
99
"@com_github_google_logger//:logger",
@@ -16,7 +16,7 @@ go_test(
1616
srcs = ["metadata_test.go"],
1717
embed = [":metadata"],
1818
deps = [
19-
"//internal/testutils",
19+
"//testutils",
2020
"@com_github_spf13_afero//:afero",
2121
"@com_github_stretchr_testify//assert",
2222
],
File renamed without changes.

internal/metadata/metadata_test.go renamed to metadata/metadata_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import (
55
"testing"
66
"time"
77

8-
"github.com/discentem/cavorite/internal/testutils"
8+
"github.com/discentem/cavorite/testutils"
99
"github.com/spf13/afero"
1010
"github.com/stretchr/testify/assert"
1111
)

plugins/localstore/BUILD.bazel

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ go_library(
66
importpath = "github.com/discentem/cavorite/plugins/localstore",
77
visibility = ["//visibility:private"],
88
deps = [
9-
"//internal/config",
10-
"//internal/stores",
9+
"//config",
10+
"//stores",
1111
"@com_github_hashicorp_go_hclog//:go-hclog",
1212
"@com_github_hashicorp_go_multierror//:go-multierror",
1313
"@com_github_spf13_afero//:afero",
@@ -25,8 +25,8 @@ go_test(
2525
srcs = ["main_test.go"],
2626
embed = [":localstore_lib"],
2727
deps = [
28-
"//internal/stores",
29-
"//internal/testutils",
28+
"//stores",
29+
"//testutils",
3030
"@com_github_carolynvs_aferox//:aferox",
3131
"@com_github_hashicorp_go_hclog//:go-hclog",
3232
"@com_github_stretchr_testify//assert",

plugins/localstore/main.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ import (
1212
multierr "github.com/hashicorp/go-multierror"
1313
"github.com/spf13/afero"
1414

15-
"github.com/discentem/cavorite/internal/config"
16-
"github.com/discentem/cavorite/internal/stores"
15+
"github.com/discentem/cavorite/config"
16+
"github.com/discentem/cavorite/stores"
1717
)
1818

1919
type LocalStore struct {

plugins/localstore/main_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ import (
66
"testing"
77

88
"github.com/carolynvs/aferox"
9-
"github.com/discentem/cavorite/internal/stores"
10-
"github.com/discentem/cavorite/internal/testutils"
9+
"github.com/discentem/cavorite/stores"
10+
"github.com/discentem/cavorite/testutils"
1111
"github.com/hashicorp/go-hclog"
1212
"github.com/stretchr/testify/assert"
1313
)

internal/program/BUILD.bazel renamed to program/BUILD.bazel

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@ load("@io_bazel_rules_go//go:def.bzl", "go_library")
33
go_library(
44
name = "program",
55
srcs = ["main.go"],
6-
importpath = "github.com/discentem/cavorite/internal/program",
6+
importpath = "github.com/discentem/cavorite/program",
77
visibility = ["//:__subpackages__"],
88
)
File renamed without changes.

internal/stores/BUILD.bazel renamed to stores/BUILD.bazel

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,12 @@ go_library(
1010
"s3.go",
1111
"stores.go",
1212
],
13-
importpath = "github.com/discentem/cavorite/internal/stores",
13+
importpath = "github.com/discentem/cavorite/stores",
1414
visibility = ["//:__subpackages__"],
1515
deps = [
16-
"//internal/fileutils",
17-
"//internal/metadata",
18-
"//internal/stores/pluginproto:pluginproto_go_proto",
16+
"//fileutils",
17+
"//metadata",
18+
"//stores/pluginproto:pluginproto_go_proto",
1919
"@com_github_aws_aws_sdk_go_v2//aws",
2020
"@com_github_aws_aws_sdk_go_v2_config//:config",
2121
"@com_github_aws_aws_sdk_go_v2_feature_s3_manager//:manager",
@@ -46,7 +46,7 @@ go_test(
4646
],
4747
embed = [":stores"],
4848
deps = [
49-
"//internal/testutils",
49+
"//testutils",
5050
"@com_github_aws_aws_sdk_go_v2_feature_s3_manager//:manager",
5151
"@com_github_aws_aws_sdk_go_v2_service_s3//:s3",
5252
"@com_github_azure_azure_sdk_for_go_sdk_storage_azblob//:azblob",

internal/stores/azure.go renamed to stores/azure.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ import (
1313
"github.com/Azure/azure-sdk-for-go/sdk/storage/azblob"
1414
"github.com/Azure/azure-sdk-for-go/sdk/storage/azblob/blob"
1515
"github.com/Azure/azure-sdk-for-go/sdk/storage/azblob/blockblob"
16-
"github.com/discentem/cavorite/internal/fileutils"
17-
"github.com/discentem/cavorite/internal/metadata"
16+
"github.com/discentem/cavorite/fileutils"
17+
"github.com/discentem/cavorite/metadata"
1818
"github.com/google/logger"
1919
"github.com/spf13/afero"
2020
)

internal/stores/azure_test.go renamed to stores/azure_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import (
99

1010
"github.com/Azure/azure-sdk-for-go/sdk/storage/azblob"
1111
"github.com/Azure/azure-sdk-for-go/sdk/storage/azblob/blob"
12-
"github.com/discentem/cavorite/internal/testutils"
12+
"github.com/discentem/cavorite/testutils"
1313
"github.com/spf13/afero"
1414
"github.com/stretchr/testify/assert"
1515
"github.com/stretchr/testify/require"

internal/stores/gcs.go renamed to stores/gcs.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ import (
99
"time"
1010

1111
gcsStorage "cloud.google.com/go/storage"
12-
"github.com/discentem/cavorite/internal/fileutils"
13-
"github.com/discentem/cavorite/internal/metadata"
12+
"github.com/discentem/cavorite/fileutils"
13+
"github.com/discentem/cavorite/metadata"
1414
"github.com/google/logger"
1515
"github.com/spf13/afero"
1616
"google.golang.org/api/option"

internal/stores/gcs_test.go renamed to stores/gcs_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import (
1111
"github.com/stretchr/testify/assert"
1212
"google.golang.org/api/option"
1313

14-
"github.com/discentem/cavorite/internal/testutils"
14+
"github.com/discentem/cavorite/testutils"
1515
)
1616

1717
func fakeBucketClient(
File renamed without changes.

internal/stores/plugin.go renamed to stores/plugin.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import (
1313
"google.golang.org/grpc/status"
1414
"google.golang.org/protobuf/types/known/emptypb"
1515

16-
"github.com/discentem/cavorite/internal/stores/pluginproto"
16+
"github.com/discentem/cavorite/stores/pluginproto"
1717
)
1818

1919
var (

internal/stores/pluginproto/BUILD.bazel renamed to stores/pluginproto/BUILD.bazel

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ proto_library(
1818
go_proto_library(
1919
name = "pluginproto_go_proto",
2020
compilers = ["@io_bazel_rules_go//proto:go_grpc"],
21-
importpath = "github.com/discentem/cavorite/internal/stores/pluginproto",
21+
importpath = "github.com/discentem/cavorite/stores/pluginproto",
2222
proto = ":plugin_proto",
2323
visibility = ["//:__subpackages__"],
2424
)

0 commit comments

Comments
 (0)