diff --git a/Makefile b/Makefile index 32165d0..a315492 100644 --- a/Makefile +++ b/Makefile @@ -13,7 +13,7 @@ generate: model mocks deepcopy-gen deepcopy-gen: tb.controller-gen @mkdir -p ./tmp @touch ./tmp/deepcopy-gen-boilerplate.go.txt - $(TB_CONTROLLER_GEN) paths=./pkg/types object + $(TB_CONTROLLER_GEN) paths=./internal/types object .PHONY: docs docs: @@ -23,7 +23,7 @@ docs: test: generate lint test-ci fuzz: - go test -fuzz=FuzzMask -v ./pkg/types/ -fuzztime=60s + go test -fuzz=FuzzMask -v ./internal/types/ -fuzztime=60s # Run ci tests test-ci: mocks tidy tb.ginkgo @@ -32,8 +32,8 @@ test-ci: mocks tidy tb.ginkgo go tool cover -func=coverage.out mocks: tb.mockgen - $(TB_MOCKGEN) -package client -destination pkg/mocks/client/mock.go github.com/bakito/adguardhome-sync/pkg/client Client - $(TB_MOCKGEN) -package client -destination pkg/mocks/flags/mock.go github.com/bakito/adguardhome-sync/pkg/config Flags + $(TB_MOCKGEN) -package client -destination internal/mocks/client/mock.go github.com/bakito/adguardhome-sync/internal/client Client + $(TB_MOCKGEN) -package client -destination internal/mocks/flags/mock.go github.com/bakito/adguardhome-sync/internal/config Flags release: tb.semver tb.goreleaser @version=$$($(TB_SEMVER)); \ @@ -80,7 +80,7 @@ ADGUARD_HOME_VERSION ?= v0.107.65 model: tb.oapi-codegen @mkdir -p tmp go run openapi/main.go $(ADGUARD_HOME_VERSION) - $(TB_OAPI_CODEGEN) -package model -generate types,client -config .oapi-codegen.yaml tmp/schema.yaml > pkg/client/model/model_generated.go + $(TB_OAPI_CODEGEN) -package model -generate types,client -config .oapi-codegen.yaml tmp/schema.yaml > internal/client/model/model_generated.go model-diff: go run openapi/main.go $(ADGUARD_HOME_VERSION) diff --git a/cmd/root.go b/cmd/root.go index ee1191e..149bca9 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -6,7 +6,7 @@ import ( "github.com/spf13/cobra" - "github.com/bakito/adguardhome-sync/pkg/log" + "github.com/bakito/adguardhome-sync/internal/log" "github.com/bakito/adguardhome-sync/version" ) diff --git a/cmd/run.go b/cmd/run.go index f059467..3b0b1d8 100644 --- a/cmd/run.go +++ b/cmd/run.go @@ -3,9 +3,9 @@ package cmd import ( "github.com/spf13/cobra" - "github.com/bakito/adguardhome-sync/pkg/config" - "github.com/bakito/adguardhome-sync/pkg/log" - "github.com/bakito/adguardhome-sync/pkg/sync" + "github.com/bakito/adguardhome-sync/internal/config" + "github.com/bakito/adguardhome-sync/internal/log" + "github.com/bakito/adguardhome-sync/internal/sync" ) // runCmd represents the run command. diff --git a/docs/main.go b/docs/main.go index 25aac65..81bebc4 100644 --- a/docs/main.go +++ b/docs/main.go @@ -9,7 +9,7 @@ import ( "reflect" "strings" - "github.com/bakito/adguardhome-sync/pkg/types" + "github.com/bakito/adguardhome-sync/internal/types" ) func main() { diff --git a/pkg/client/client-methods.go b/internal/client/client-methods.go similarity index 100% rename from pkg/client/client-methods.go rename to internal/client/client-methods.go diff --git a/pkg/client/client.go b/internal/client/client.go similarity index 98% rename from pkg/client/client.go rename to internal/client/client.go index d2db441..9ab9292 100644 --- a/pkg/client/client.go +++ b/internal/client/client.go @@ -14,10 +14,10 @@ import ( "github.com/go-resty/resty/v2" "go.uber.org/zap" - "github.com/bakito/adguardhome-sync/pkg/client/model" - "github.com/bakito/adguardhome-sync/pkg/log" - "github.com/bakito/adguardhome-sync/pkg/types" - "github.com/bakito/adguardhome-sync/pkg/utils" + "github.com/bakito/adguardhome-sync/internal/client/model" + "github.com/bakito/adguardhome-sync/internal/log" + "github.com/bakito/adguardhome-sync/internal/types" + "github.com/bakito/adguardhome-sync/internal/utils" ) const envRedirectPolicyNoOfRedirects = "REDIRECT_POLICY_NO_OF_REDIRECTS" diff --git a/pkg/client/client_suite_test.go b/internal/client/client_suite_test.go similarity index 100% rename from pkg/client/client_suite_test.go rename to internal/client/client_suite_test.go diff --git a/pkg/client/client_test.go b/internal/client/client_test.go similarity index 98% rename from pkg/client/client_test.go rename to internal/client/client_test.go index 4b0e1fd..8c998f9 100644 --- a/pkg/client/client_test.go +++ b/internal/client/client_test.go @@ -12,10 +12,10 @@ import ( . "github.com/onsi/ginkgo/v2" . "github.com/onsi/gomega" - "github.com/bakito/adguardhome-sync/pkg/client" - "github.com/bakito/adguardhome-sync/pkg/client/model" - "github.com/bakito/adguardhome-sync/pkg/types" - "github.com/bakito/adguardhome-sync/pkg/utils" + "github.com/bakito/adguardhome-sync/internal/client" + "github.com/bakito/adguardhome-sync/internal/client/model" + "github.com/bakito/adguardhome-sync/internal/types" + "github.com/bakito/adguardhome-sync/internal/utils" ) var ( diff --git a/pkg/client/model/client/client.go b/internal/client/model/client/client.go similarity index 95% rename from pkg/client/model/client/client.go rename to internal/client/model/client/client.go index 2932cef..1d714f1 100644 --- a/pkg/client/model/client/client.go +++ b/internal/client/model/client/client.go @@ -13,9 +13,9 @@ import ( "go.uber.org/zap" - "github.com/bakito/adguardhome-sync/pkg/client/model" - "github.com/bakito/adguardhome-sync/pkg/log" - "github.com/bakito/adguardhome-sync/pkg/types" + "github.com/bakito/adguardhome-sync/internal/client/model" + "github.com/bakito/adguardhome-sync/internal/log" + "github.com/bakito/adguardhome-sync/internal/types" ) var l = log.GetLogger("client") diff --git a/pkg/client/model/client/interface.go b/internal/client/model/client/interface.go similarity index 83% rename from pkg/client/model/client/interface.go rename to internal/client/model/client/interface.go index 3ad23c4..d58b28c 100644 --- a/pkg/client/model/client/interface.go +++ b/internal/client/model/client/interface.go @@ -3,7 +3,7 @@ package client import ( "context" - "github.com/bakito/adguardhome-sync/pkg/client/model" + "github.com/bakito/adguardhome-sync/internal/client/model" ) type Client interface { diff --git a/pkg/client/model/client/resty.go b/internal/client/model/client/resty.go similarity index 88% rename from pkg/client/model/client/resty.go rename to internal/client/model/client/resty.go index 3d4f3e1..34843dc 100644 --- a/pkg/client/model/client/resty.go +++ b/internal/client/model/client/resty.go @@ -5,7 +5,7 @@ import ( "github.com/go-resty/resty/v2" - "github.com/bakito/adguardhome-sync/pkg/client/model" + "github.com/bakito/adguardhome-sync/internal/client/model" ) var _ model.HttpRequestDoer = &adapter{} diff --git a/pkg/client/model/model-functions.go b/internal/client/model/model-functions.go similarity index 99% rename from pkg/client/model/model-functions.go rename to internal/client/model/model-functions.go index 6d22e9d..0060e25 100644 --- a/pkg/client/model/model-functions.go +++ b/internal/client/model/model-functions.go @@ -9,7 +9,7 @@ import ( "go.uber.org/zap" "k8s.io/utils/ptr" - "github.com/bakito/adguardhome-sync/pkg/utils" + "github.com/bakito/adguardhome-sync/internal/utils" ) // Clone the config. diff --git a/pkg/client/model/model_generated.go b/internal/client/model/model_generated.go similarity index 100% rename from pkg/client/model/model_generated.go rename to internal/client/model/model_generated.go diff --git a/pkg/client/model/model_private_test.go b/internal/client/model/model_private_test.go similarity index 96% rename from pkg/client/model/model_private_test.go rename to internal/client/model/model_private_test.go index 95064b0..048c3a0 100644 --- a/pkg/client/model/model_private_test.go +++ b/internal/client/model/model_private_test.go @@ -5,8 +5,8 @@ import ( "github.com/onsi/gomega" "go.uber.org/zap" - "github.com/bakito/adguardhome-sync/pkg/log" - "github.com/bakito/adguardhome-sync/pkg/utils" + "github.com/bakito/adguardhome-sync/internal/log" + "github.com/bakito/adguardhome-sync/internal/utils" ) var _ = Describe("Types", func() { diff --git a/pkg/client/model/model_suite_test.go b/internal/client/model/model_suite_test.go similarity index 100% rename from pkg/client/model/model_suite_test.go rename to internal/client/model/model_suite_test.go diff --git a/pkg/client/model/model_test.go b/internal/client/model/model_test.go similarity index 98% rename from pkg/client/model/model_test.go rename to internal/client/model/model_test.go index afd2097..f0ae048 100644 --- a/pkg/client/model/model_test.go +++ b/internal/client/model/model_test.go @@ -8,9 +8,9 @@ import ( . "github.com/onsi/ginkgo/v2" . "github.com/onsi/gomega" - "github.com/bakito/adguardhome-sync/pkg/client/model" - "github.com/bakito/adguardhome-sync/pkg/types" - "github.com/bakito/adguardhome-sync/pkg/utils" + "github.com/bakito/adguardhome-sync/internal/client/model" + "github.com/bakito/adguardhome-sync/internal/types" + "github.com/bakito/adguardhome-sync/internal/utils" ) var _ = Describe("Types", func() { diff --git a/pkg/config/config-schema.json b/internal/config/config-schema.json similarity index 100% rename from pkg/config/config-schema.json rename to internal/config/config-schema.json diff --git a/pkg/config/config.go b/internal/config/config.go similarity index 96% rename from pkg/config/config.go rename to internal/config/config.go index f09ea46..7c4f4ab 100644 --- a/pkg/config/config.go +++ b/internal/config/config.go @@ -6,8 +6,8 @@ import ( "github.com/caarlos0/env/v11" - "github.com/bakito/adguardhome-sync/pkg/log" - "github.com/bakito/adguardhome-sync/pkg/types" + "github.com/bakito/adguardhome-sync/internal/log" + "github.com/bakito/adguardhome-sync/internal/types" ) var ( diff --git a/pkg/config/config_suite_test.go b/internal/config/config_suite_test.go similarity index 100% rename from pkg/config/config_suite_test.go rename to internal/config/config_suite_test.go diff --git a/pkg/config/config_test.go b/internal/config/config_test.go similarity index 98% rename from pkg/config/config_test.go rename to internal/config/config_test.go index c4777de..7985f0d 100644 --- a/pkg/config/config_test.go +++ b/internal/config/config_test.go @@ -7,8 +7,8 @@ import ( . "github.com/onsi/gomega" gm "go.uber.org/mock/gomock" - "github.com/bakito/adguardhome-sync/pkg/config" - flagsmock "github.com/bakito/adguardhome-sync/pkg/mocks/flags" + "github.com/bakito/adguardhome-sync/internal/config" + flagsmock "github.com/bakito/adguardhome-sync/internal/mocks/flags" ) var _ = Describe("Config", func() { diff --git a/pkg/config/env.go b/internal/config/env.go similarity index 96% rename from pkg/config/env.go rename to internal/config/env.go index 03a764e..a39274a 100644 --- a/pkg/config/env.go +++ b/internal/config/env.go @@ -7,7 +7,7 @@ import ( "github.com/caarlos0/env/v11" - "github.com/bakito/adguardhome-sync/pkg/types" + "github.com/bakito/adguardhome-sync/internal/types" ) // Manually collect replicas from env. diff --git a/pkg/config/env_test.go b/internal/config/env_test.go similarity index 100% rename from pkg/config/env_test.go rename to internal/config/env_test.go diff --git a/pkg/config/file.go b/internal/config/file.go similarity index 92% rename from pkg/config/file.go rename to internal/config/file.go index dbe43d8..e25c6bf 100644 --- a/pkg/config/file.go +++ b/internal/config/file.go @@ -6,7 +6,7 @@ import ( "gopkg.in/yaml.v3" - "github.com/bakito/adguardhome-sync/pkg/types" + "github.com/bakito/adguardhome-sync/internal/types" ) func readFile(cfg *types.Config, path string) (string, error) { diff --git a/pkg/config/file_test.go b/internal/config/file_test.go similarity index 100% rename from pkg/config/file_test.go rename to internal/config/file_test.go diff --git a/pkg/config/flag-names.go b/internal/config/flag-names.go similarity index 100% rename from pkg/config/flag-names.go rename to internal/config/flag-names.go diff --git a/pkg/config/flags.go b/internal/config/flags.go similarity index 99% rename from pkg/config/flags.go rename to internal/config/flags.go index 04741a4..482b37e 100644 --- a/pkg/config/flags.go +++ b/internal/config/flags.go @@ -1,7 +1,7 @@ package config import ( - "github.com/bakito/adguardhome-sync/pkg/types" + "github.com/bakito/adguardhome-sync/internal/types" ) func readFlags(cfg *types.Config, flags Flags) error { diff --git a/pkg/config/flags_test.go b/internal/config/flags_test.go similarity index 98% rename from pkg/config/flags_test.go rename to internal/config/flags_test.go index 8fe56a2..9fd8f43 100644 --- a/pkg/config/flags_test.go +++ b/internal/config/flags_test.go @@ -7,8 +7,8 @@ import ( . "github.com/onsi/gomega" gm "go.uber.org/mock/gomock" - flagsmock "github.com/bakito/adguardhome-sync/pkg/mocks/flags" - "github.com/bakito/adguardhome-sync/pkg/types" + flagsmock "github.com/bakito/adguardhome-sync/internal/mocks/flags" + "github.com/bakito/adguardhome-sync/internal/types" ) var _ = Describe("Config", func() { diff --git a/pkg/config/print-config.go b/internal/config/print-config.go similarity index 94% rename from pkg/config/print-config.go rename to internal/config/print-config.go index 382be75..39a82df 100644 --- a/pkg/config/print-config.go +++ b/internal/config/print-config.go @@ -11,8 +11,8 @@ import ( "gopkg.in/yaml.v3" - "github.com/bakito/adguardhome-sync/pkg/client" - "github.com/bakito/adguardhome-sync/pkg/types" + "github.com/bakito/adguardhome-sync/internal/client" + "github.com/bakito/adguardhome-sync/internal/types" "github.com/bakito/adguardhome-sync/version" ) diff --git a/pkg/config/print-config.md b/internal/config/print-config.md similarity index 100% rename from pkg/config/print-config.md rename to internal/config/print-config.md diff --git a/pkg/config/print-config_test.go b/internal/config/print-config_test.go similarity index 92% rename from pkg/config/print-config_test.go rename to internal/config/print-config_test.go index df89708..95f0ec0 100644 --- a/pkg/config/print-config_test.go +++ b/internal/config/print-config_test.go @@ -10,8 +10,8 @@ import ( . "github.com/onsi/ginkgo/v2" . "github.com/onsi/gomega" - "github.com/bakito/adguardhome-sync/pkg/test/matchers" - "github.com/bakito/adguardhome-sync/pkg/types" + "github.com/bakito/adguardhome-sync/internal/test/matchers" + "github.com/bakito/adguardhome-sync/internal/types" "github.com/bakito/adguardhome-sync/version" ) diff --git a/pkg/config/validate.go b/internal/config/validate.go similarity index 100% rename from pkg/config/validate.go rename to internal/config/validate.go diff --git a/pkg/config/validate_test.go b/internal/config/validate_test.go similarity index 95% rename from pkg/config/validate_test.go rename to internal/config/validate_test.go index decc5e7..b46f5d1 100644 --- a/pkg/config/validate_test.go +++ b/internal/config/validate_test.go @@ -6,7 +6,7 @@ import ( . "github.com/onsi/gomega" "gopkg.in/yaml.v3" - "github.com/bakito/adguardhome-sync/pkg/types" + "github.com/bakito/adguardhome-sync/internal/types" ) var _ = Describe("Config", func() { diff --git a/pkg/log/log.go b/internal/log/log.go similarity index 100% rename from pkg/log/log.go rename to internal/log/log.go diff --git a/pkg/metrics/handler.go b/internal/metrics/handler.go similarity index 100% rename from pkg/metrics/handler.go rename to internal/metrics/handler.go diff --git a/pkg/metrics/metrics.go b/internal/metrics/metrics.go similarity index 98% rename from pkg/metrics/metrics.go rename to internal/metrics/metrics.go index 7efacf1..84a08ec 100644 --- a/pkg/metrics/metrics.go +++ b/internal/metrics/metrics.go @@ -3,8 +3,8 @@ package metrics import ( "github.com/prometheus/client_golang/prometheus" - "github.com/bakito/adguardhome-sync/pkg/client/model" - "github.com/bakito/adguardhome-sync/pkg/log" + "github.com/bakito/adguardhome-sync/internal/client/model" + "github.com/bakito/adguardhome-sync/internal/log" ) const StatsTotal = "total" diff --git a/pkg/metrics/metrics_suite_test.go b/internal/metrics/metrics_suite_test.go similarity index 100% rename from pkg/metrics/metrics_suite_test.go rename to internal/metrics/metrics_suite_test.go diff --git a/pkg/metrics/metrics_test.go b/internal/metrics/metrics_test.go similarity index 97% rename from pkg/metrics/metrics_test.go rename to internal/metrics/metrics_test.go index 1a37251..2221058 100644 --- a/pkg/metrics/metrics_test.go +++ b/internal/metrics/metrics_test.go @@ -6,7 +6,7 @@ import ( . "github.com/onsi/gomega" "k8s.io/utils/ptr" - "github.com/bakito/adguardhome-sync/pkg/client/model" + "github.com/bakito/adguardhome-sync/internal/client/model" ) var _ = Describe("Metrics", func() { diff --git a/pkg/metrics/stats.go b/internal/metrics/stats.go similarity index 97% rename from pkg/metrics/stats.go rename to internal/metrics/stats.go index 10cb3e1..1225a9f 100644 --- a/pkg/metrics/stats.go +++ b/internal/metrics/stats.go @@ -4,7 +4,7 @@ import ( "slices" "strings" - "github.com/bakito/adguardhome-sync/pkg/client/model" + "github.com/bakito/adguardhome-sync/internal/client/model" ) const labelTotal = "Total" diff --git a/pkg/mocks/client/mock.go b/internal/mocks/client/mock.go similarity index 98% rename from pkg/mocks/client/mock.go rename to internal/mocks/client/mock.go index 688a3a1..843f545 100644 --- a/pkg/mocks/client/mock.go +++ b/internal/mocks/client/mock.go @@ -1,9 +1,9 @@ // Code generated by MockGen. DO NOT EDIT. -// Source: github.com/bakito/adguardhome-sync/pkg/client (interfaces: Client) +// Source: github.com/bakito/adguardhome-sync/internal/client (interfaces: Client) // // Generated by this command: // -// mockgen -package client -destination pkg/mocks/client/mock.go github.com/bakito/adguardhome-sync/pkg/client Client +// mockgen -package client -destination internal/mocks/client/mock.go github.com/bakito/adguardhome-sync/internal/client Client // // Package client is a generated GoMock package. @@ -12,7 +12,7 @@ package client import ( reflect "reflect" - model "github.com/bakito/adguardhome-sync/pkg/client/model" + model "github.com/bakito/adguardhome-sync/internal/client/model" gomock "go.uber.org/mock/gomock" ) diff --git a/pkg/mocks/flags/mock.go b/internal/mocks/flags/mock.go similarity index 92% rename from pkg/mocks/flags/mock.go rename to internal/mocks/flags/mock.go index 71d69bc..e615b08 100644 --- a/pkg/mocks/flags/mock.go +++ b/internal/mocks/flags/mock.go @@ -1,9 +1,9 @@ // Code generated by MockGen. DO NOT EDIT. -// Source: github.com/bakito/adguardhome-sync/pkg/config (interfaces: Flags) +// Source: github.com/bakito/adguardhome-sync/internal/config (interfaces: Flags) // // Generated by this command: // -// mockgen -package client -destination pkg/mocks/flags/mock.go github.com/bakito/adguardhome-sync/pkg/config Flags +// mockgen -package client -destination internal/mocks/flags/mock.go github.com/bakito/adguardhome-sync/internal/config Flags // // Package client is a generated GoMock package. diff --git a/pkg/sync/action-general.go b/internal/sync/action-general.go similarity index 97% rename from pkg/sync/action-general.go rename to internal/sync/action-general.go index ccd00c2..288c3f0 100644 --- a/pkg/sync/action-general.go +++ b/internal/sync/action-general.go @@ -3,9 +3,9 @@ package sync import ( "go.uber.org/zap" - "github.com/bakito/adguardhome-sync/pkg/client" - "github.com/bakito/adguardhome-sync/pkg/client/model" - "github.com/bakito/adguardhome-sync/pkg/utils" + "github.com/bakito/adguardhome-sync/internal/client" + "github.com/bakito/adguardhome-sync/internal/client/model" + "github.com/bakito/adguardhome-sync/internal/utils" ) var ( diff --git a/pkg/sync/action.go b/internal/sync/action.go similarity index 93% rename from pkg/sync/action.go rename to internal/sync/action.go index e4d3edc..fcf9c18 100644 --- a/pkg/sync/action.go +++ b/internal/sync/action.go @@ -3,9 +3,9 @@ package sync import ( "go.uber.org/zap" - "github.com/bakito/adguardhome-sync/pkg/client" - "github.com/bakito/adguardhome-sync/pkg/client/model" - "github.com/bakito/adguardhome-sync/pkg/types" + "github.com/bakito/adguardhome-sync/internal/client" + "github.com/bakito/adguardhome-sync/internal/client/model" + "github.com/bakito/adguardhome-sync/internal/types" ) func setupActions(cfg *types.Config) (actions []syncAction) { diff --git a/pkg/sync/favicon.ico b/internal/sync/favicon.ico similarity index 100% rename from pkg/sync/favicon.ico rename to internal/sync/favicon.ico diff --git a/pkg/sync/http.go b/internal/sync/http.go similarity index 98% rename from pkg/sync/http.go rename to internal/sync/http.go index 3803924..ee7cea4 100644 --- a/pkg/sync/http.go +++ b/internal/sync/http.go @@ -16,8 +16,8 @@ import ( "github.com/gin-gonic/gin" - "github.com/bakito/adguardhome-sync/pkg/log" - "github.com/bakito/adguardhome-sync/pkg/metrics" + "github.com/bakito/adguardhome-sync/internal/log" + "github.com/bakito/adguardhome-sync/internal/metrics" "github.com/bakito/adguardhome-sync/version" ) diff --git a/pkg/sync/index.html b/internal/sync/index.html similarity index 100% rename from pkg/sync/index.html rename to internal/sync/index.html diff --git a/pkg/sync/logo.svg b/internal/sync/logo.svg similarity index 100% rename from pkg/sync/logo.svg rename to internal/sync/logo.svg diff --git a/pkg/sync/scrape.go b/internal/sync/scrape.go similarity index 91% rename from pkg/sync/scrape.go rename to internal/sync/scrape.go index 3932ea9..fc5bc70 100644 --- a/pkg/sync/scrape.go +++ b/internal/sync/scrape.go @@ -3,8 +3,8 @@ package sync import ( "time" - "github.com/bakito/adguardhome-sync/pkg/metrics" - "github.com/bakito/adguardhome-sync/pkg/types" + "github.com/bakito/adguardhome-sync/internal/metrics" + "github.com/bakito/adguardhome-sync/internal/types" ) func (w *worker) startScraping() { diff --git a/pkg/sync/sync.go b/internal/sync/sync.go similarity index 95% rename from pkg/sync/sync.go rename to internal/sync/sync.go index 3985f02..a94cc5c 100644 --- a/pkg/sync/sync.go +++ b/internal/sync/sync.go @@ -11,13 +11,13 @@ import ( "github.com/robfig/cron/v3" "go.uber.org/zap" - "github.com/bakito/adguardhome-sync/pkg/client" - "github.com/bakito/adguardhome-sync/pkg/client/model" - "github.com/bakito/adguardhome-sync/pkg/log" - "github.com/bakito/adguardhome-sync/pkg/metrics" - "github.com/bakito/adguardhome-sync/pkg/types" - "github.com/bakito/adguardhome-sync/pkg/utils" - "github.com/bakito/adguardhome-sync/pkg/versions" + "github.com/bakito/adguardhome-sync/internal/client" + "github.com/bakito/adguardhome-sync/internal/client/model" + "github.com/bakito/adguardhome-sync/internal/log" + "github.com/bakito/adguardhome-sync/internal/metrics" + "github.com/bakito/adguardhome-sync/internal/types" + "github.com/bakito/adguardhome-sync/internal/utils" + "github.com/bakito/adguardhome-sync/internal/versions" "github.com/bakito/adguardhome-sync/version" ) diff --git a/pkg/sync/sync_suite_test.go b/internal/sync/sync_suite_test.go similarity index 100% rename from pkg/sync/sync_suite_test.go rename to internal/sync/sync_suite_test.go diff --git a/pkg/sync/sync_test.go b/internal/sync/sync_test.go similarity index 98% rename from pkg/sync/sync_test.go rename to internal/sync/sync_test.go index c51e95e..298a596 100644 --- a/pkg/sync/sync_test.go +++ b/internal/sync/sync_test.go @@ -8,12 +8,12 @@ import ( . "github.com/onsi/gomega" gm "go.uber.org/mock/gomock" - "github.com/bakito/adguardhome-sync/pkg/client" - "github.com/bakito/adguardhome-sync/pkg/client/model" - clientmock "github.com/bakito/adguardhome-sync/pkg/mocks/client" - "github.com/bakito/adguardhome-sync/pkg/types" - "github.com/bakito/adguardhome-sync/pkg/utils" - "github.com/bakito/adguardhome-sync/pkg/versions" + "github.com/bakito/adguardhome-sync/internal/client" + "github.com/bakito/adguardhome-sync/internal/client/model" + clientmock "github.com/bakito/adguardhome-sync/internal/mocks/client" + "github.com/bakito/adguardhome-sync/internal/types" + "github.com/bakito/adguardhome-sync/internal/utils" + "github.com/bakito/adguardhome-sync/internal/versions" ) var _ = Describe("Sync", func() { diff --git a/pkg/test/matchers/matchers.go b/internal/test/matchers/matchers.go similarity index 100% rename from pkg/test/matchers/matchers.go rename to internal/test/matchers/matchers.go diff --git a/pkg/types/features.go b/internal/types/features.go similarity index 100% rename from pkg/types/features.go rename to internal/types/features.go diff --git a/pkg/types/types.go b/internal/types/types.go similarity index 100% rename from pkg/types/types.go rename to internal/types/types.go diff --git a/pkg/types/types_fuzz_test.go b/internal/types/types_fuzz_test.go similarity index 100% rename from pkg/types/types_fuzz_test.go rename to internal/types/types_fuzz_test.go diff --git a/pkg/types/types_suite_test.go b/internal/types/types_suite_test.go similarity index 100% rename from pkg/types/types_suite_test.go rename to internal/types/types_suite_test.go diff --git a/pkg/types/types_test.go b/internal/types/types_test.go similarity index 100% rename from pkg/types/types_test.go rename to internal/types/types_test.go diff --git a/pkg/types/zz_generated.deepcopy.go b/internal/types/zz_generated.deepcopy.go similarity index 100% rename from pkg/types/zz_generated.deepcopy.go rename to internal/types/zz_generated.deepcopy.go diff --git a/pkg/utils/clone.go b/internal/utils/clone.go similarity index 100% rename from pkg/utils/clone.go rename to internal/utils/clone.go diff --git a/pkg/utils/ptr.go b/internal/utils/ptr.go similarity index 100% rename from pkg/utils/ptr.go rename to internal/utils/ptr.go diff --git a/pkg/versions/versions.go b/internal/versions/versions.go similarity index 100% rename from pkg/versions/versions.go rename to internal/versions/versions.go diff --git a/pkg/versions/versions_suite_test.go b/internal/versions/versions_suite_test.go similarity index 100% rename from pkg/versions/versions_suite_test.go rename to internal/versions/versions_suite_test.go diff --git a/pkg/versions/versions_test.go b/internal/versions/versions_test.go similarity index 94% rename from pkg/versions/versions_test.go rename to internal/versions/versions_test.go index 9de2e07..d6e46e0 100644 --- a/pkg/versions/versions_test.go +++ b/internal/versions/versions_test.go @@ -4,7 +4,7 @@ import ( . "github.com/onsi/ginkgo/v2" . "github.com/onsi/gomega" - "github.com/bakito/adguardhome-sync/pkg/versions" + "github.com/bakito/adguardhome-sync/internal/versions" ) var _ = Describe("Versions", func() {