Skip to content

Commit 23990da

Browse files
authored
Move all internal/ packages to a root internal/ (google#983)
This will simplify my life a bit.
1 parent 549ee62 commit 23990da

Some content is hidden

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

49 files changed

+36
-36
lines changed
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

pkg/v1/internal/estargz/estargz_test.go renamed to internal/estargz/estargz_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ import (
2323
"strings"
2424
"testing"
2525

26-
"github.com/google/go-containerregistry/pkg/v1/internal/gzip"
26+
"github.com/google/go-containerregistry/internal/gzip"
2727
)
2828

2929
func TestReader(t *testing.T) {

pkg/v1/internal/gzip/zip.go renamed to internal/gzip/zip.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import (
2020
"compress/gzip"
2121
"io"
2222

23-
"github.com/google/go-containerregistry/pkg/v1/internal/and"
23+
"github.com/google/go-containerregistry/internal/and"
2424
)
2525

2626
var gzipMagicHeader = []byte{'\x1f', '\x8b'}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

pkg/internal/retry/retry.go renamed to internal/retry/retry.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import (
2020
"context"
2121
"fmt"
2222

23-
"github.com/google/go-containerregistry/pkg/internal/retry/wait"
23+
"github.com/google/go-containerregistry/internal/retry/wait"
2424
)
2525

2626
// Backoff is an alias of our own wait.Backoff to avoid name conflicts with
File renamed without changes.

pkg/v1/internal/verify/verify.go renamed to internal/verify/verify.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ import (
2020
"hash"
2121
"io"
2222

23+
"github.com/google/go-containerregistry/internal/and"
2324
v1 "github.com/google/go-containerregistry/pkg/v1"
24-
"github.com/google/go-containerregistry/pkg/v1/internal/and"
2525
)
2626

2727
type verifyReader struct {

pkg/crane/copy.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ package crane
1717
import (
1818
"fmt"
1919

20+
"github.com/google/go-containerregistry/internal/legacy"
2021
"github.com/google/go-containerregistry/pkg/authn"
21-
"github.com/google/go-containerregistry/pkg/internal/legacy"
2222
"github.com/google/go-containerregistry/pkg/logs"
2323
"github.com/google/go-containerregistry/pkg/name"
2424
"github.com/google/go-containerregistry/pkg/v1/remote"

pkg/crane/crane_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@ import (
2828
"strings"
2929
"testing"
3030

31+
"github.com/google/go-containerregistry/internal/compare"
3132
"github.com/google/go-containerregistry/pkg/authn"
3233
"github.com/google/go-containerregistry/pkg/crane"
33-
"github.com/google/go-containerregistry/pkg/internal/compare"
3434
"github.com/google/go-containerregistry/pkg/name"
3535
"github.com/google/go-containerregistry/pkg/registry"
3636
v1 "github.com/google/go-containerregistry/pkg/v1"

pkg/gcrane/copy.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,9 @@ import (
2121
"strings"
2222
"time"
2323

24+
"github.com/google/go-containerregistry/internal/retry"
2425
"github.com/google/go-containerregistry/pkg/authn"
2526
"github.com/google/go-containerregistry/pkg/crane"
26-
"github.com/google/go-containerregistry/pkg/internal/retry"
2727
"github.com/google/go-containerregistry/pkg/logs"
2828
"github.com/google/go-containerregistry/pkg/name"
2929
"github.com/google/go-containerregistry/pkg/v1/google"

pkg/gcrane/copy_test.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ import (
2929
"time"
3030

3131
"github.com/google/go-cmp/cmp"
32-
ggcrtest "github.com/google/go-containerregistry/pkg/internal/httptest"
33-
"github.com/google/go-containerregistry/pkg/internal/retry"
32+
ggcrtest "github.com/google/go-containerregistry/internal/httptest"
33+
"github.com/google/go-containerregistry/internal/retry"
3434
"github.com/google/go-containerregistry/pkg/logs"
3535
"github.com/google/go-containerregistry/pkg/name"
3636
"github.com/google/go-containerregistry/pkg/registry"

pkg/legacy/tarball/write_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ import (
2424
"strings"
2525
"testing"
2626

27-
"github.com/google/go-containerregistry/pkg/internal/compare"
27+
"github.com/google/go-containerregistry/internal/compare"
2828
"github.com/google/go-containerregistry/pkg/name"
2929
v1 "github.com/google/go-containerregistry/pkg/v1"
3030
"github.com/google/go-containerregistry/pkg/v1/mutate"

pkg/registry/tls.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ package registry
1717
import (
1818
"net/http/httptest"
1919

20-
ggcrtest "github.com/google/go-containerregistry/pkg/internal/httptest"
20+
ggcrtest "github.com/google/go-containerregistry/internal/httptest"
2121
)
2222

2323
// TLS returns an httptest server, with an http client that has been configured to

pkg/v1/daemon/image_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import (
2121
"os"
2222
"testing"
2323

24-
"github.com/google/go-containerregistry/pkg/internal/compare"
24+
"github.com/google/go-containerregistry/internal/compare"
2525
"github.com/google/go-containerregistry/pkg/name"
2626

2727
"github.com/google/go-containerregistry/pkg/v1/tarball"

pkg/v1/mutate/mutate.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ import (
2424
"strings"
2525
"time"
2626

27+
"github.com/google/go-containerregistry/internal/gzip"
2728
v1 "github.com/google/go-containerregistry/pkg/v1"
2829
"github.com/google/go-containerregistry/pkg/v1/empty"
29-
"github.com/google/go-containerregistry/pkg/v1/internal/gzip"
3030
"github.com/google/go-containerregistry/pkg/v1/match"
3131
"github.com/google/go-containerregistry/pkg/v1/tarball"
3232
"github.com/google/go-containerregistry/pkg/v1/types"

pkg/v1/partial/compressed.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ package partial
1717
import (
1818
"io"
1919

20+
"github.com/google/go-containerregistry/internal/gzip"
2021
v1 "github.com/google/go-containerregistry/pkg/v1"
21-
"github.com/google/go-containerregistry/pkg/v1/internal/gzip"
2222
"github.com/google/go-containerregistry/pkg/v1/types"
2323
)
2424

pkg/v1/partial/compressed_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ import (
1919
"testing"
2020

2121
"github.com/google/go-cmp/cmp"
22-
"github.com/google/go-containerregistry/pkg/internal/compare"
22+
"github.com/google/go-containerregistry/internal/compare"
2323
"github.com/google/go-containerregistry/pkg/name"
2424
"github.com/google/go-containerregistry/pkg/registry"
2525
v1 "github.com/google/go-containerregistry/pkg/v1"

pkg/v1/partial/uncompressed.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ import (
1919
"io"
2020
"sync"
2121

22+
"github.com/google/go-containerregistry/internal/gzip"
2223
v1 "github.com/google/go-containerregistry/pkg/v1"
23-
"github.com/google/go-containerregistry/pkg/v1/internal/gzip"
2424
"github.com/google/go-containerregistry/pkg/v1/types"
2525
)
2626

pkg/v1/partial/uncompressed_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import (
2020
"os"
2121
"testing"
2222

23-
"github.com/google/go-containerregistry/pkg/internal/compare"
23+
"github.com/google/go-containerregistry/internal/compare"
2424
legacy "github.com/google/go-containerregistry/pkg/legacy/tarball"
2525
"github.com/google/go-containerregistry/pkg/name"
2626
v1 "github.com/google/go-containerregistry/pkg/v1"

pkg/v1/remote/descriptor.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@ import (
2525
"strconv"
2626
"strings"
2727

28+
"github.com/google/go-containerregistry/internal/verify"
2829
"github.com/google/go-containerregistry/pkg/logs"
2930
"github.com/google/go-containerregistry/pkg/name"
3031
v1 "github.com/google/go-containerregistry/pkg/v1"
31-
"github.com/google/go-containerregistry/pkg/v1/internal/verify"
3232
"github.com/google/go-containerregistry/pkg/v1/partial"
3333
"github.com/google/go-containerregistry/pkg/v1/remote/transport"
3434
"github.com/google/go-containerregistry/pkg/v1/types"

pkg/v1/remote/image.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,10 @@ import (
2121
"net/url"
2222
"sync"
2323

24-
"github.com/google/go-containerregistry/pkg/internal/redact"
24+
"github.com/google/go-containerregistry/internal/redact"
25+
"github.com/google/go-containerregistry/internal/verify"
2526
"github.com/google/go-containerregistry/pkg/name"
2627
v1 "github.com/google/go-containerregistry/pkg/v1"
27-
"github.com/google/go-containerregistry/pkg/v1/internal/verify"
2828
"github.com/google/go-containerregistry/pkg/v1/partial"
2929
"github.com/google/go-containerregistry/pkg/v1/remote/transport"
3030
"github.com/google/go-containerregistry/pkg/v1/types"

pkg/v1/remote/layer.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ package remote
1717
import (
1818
"io"
1919

20-
"github.com/google/go-containerregistry/pkg/internal/redact"
20+
"github.com/google/go-containerregistry/internal/redact"
2121
"github.com/google/go-containerregistry/pkg/name"
2222
v1 "github.com/google/go-containerregistry/pkg/v1"
2323
"github.com/google/go-containerregistry/pkg/v1/partial"

pkg/v1/remote/layer_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import (
2020
"net/url"
2121
"testing"
2222

23-
"github.com/google/go-containerregistry/pkg/internal/compare"
23+
"github.com/google/go-containerregistry/internal/compare"
2424
"github.com/google/go-containerregistry/pkg/name"
2525
"github.com/google/go-containerregistry/pkg/registry"
2626
"github.com/google/go-containerregistry/pkg/v1/empty"

pkg/v1/remote/transport/bearer.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ import (
2525
"strings"
2626

2727
authchallenge "github.com/docker/distribution/registry/client/auth/challenge"
28+
"github.com/google/go-containerregistry/internal/redact"
2829
"github.com/google/go-containerregistry/pkg/authn"
29-
"github.com/google/go-containerregistry/pkg/internal/redact"
3030
"github.com/google/go-containerregistry/pkg/name"
3131
)
3232

pkg/v1/remote/transport/error.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ func (e *Error) Temporary() bool {
100100
return true
101101
}
102102

103-
// TODO(jonjohnsonjr): Consider moving to pkg/internal/redact.
103+
// TODO(jonjohnsonjr): Consider moving to internal/redact.
104104
func redactURL(original *url.URL) *url.URL {
105105
qs := original.Query()
106106
for k, v := range qs {

pkg/v1/remote/transport/logger.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import (
2020
"net/http/httputil"
2121
"time"
2222

23-
"github.com/google/go-containerregistry/pkg/internal/redact"
23+
"github.com/google/go-containerregistry/internal/redact"
2424
"github.com/google/go-containerregistry/pkg/logs"
2525
)
2626

pkg/v1/remote/transport/logger_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ import (
2323
"strings"
2424
"testing"
2525

26-
"github.com/google/go-containerregistry/pkg/internal/redact"
26+
"github.com/google/go-containerregistry/internal/redact"
2727
"github.com/google/go-containerregistry/pkg/logs"
2828
)
2929

pkg/v1/remote/transport/retry.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import (
1818
"net/http"
1919
"time"
2020

21-
"github.com/google/go-containerregistry/pkg/internal/retry"
21+
"github.com/google/go-containerregistry/internal/retry"
2222
)
2323

2424
// Sleep for 0.1, 0.3, 0.9, 2.7 seconds. This should cover networking blips.

pkg/v1/remote/transport/retry_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import (
2121
"testing"
2222
"time"
2323

24-
"github.com/google/go-containerregistry/pkg/internal/retry"
24+
"github.com/google/go-containerregistry/internal/retry"
2525
)
2626

2727
type mockTransport struct {

pkg/v1/remote/write.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@ import (
2626
"sync/atomic"
2727
"time"
2828

29-
"github.com/google/go-containerregistry/pkg/internal/redact"
30-
"github.com/google/go-containerregistry/pkg/internal/retry"
29+
"github.com/google/go-containerregistry/internal/redact"
30+
"github.com/google/go-containerregistry/internal/retry"
3131
"github.com/google/go-containerregistry/pkg/logs"
3232
"github.com/google/go-containerregistry/pkg/name"
3333
v1 "github.com/google/go-containerregistry/pkg/v1"

pkg/v1/tarball/image.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@ import (
2525
"os"
2626
"sync"
2727

28+
"github.com/google/go-containerregistry/internal/gzip"
2829
"github.com/google/go-containerregistry/pkg/name"
2930
v1 "github.com/google/go-containerregistry/pkg/v1"
30-
"github.com/google/go-containerregistry/pkg/v1/internal/gzip"
3131
"github.com/google/go-containerregistry/pkg/v1/partial"
3232
"github.com/google/go-containerregistry/pkg/v1/types"
3333
)

pkg/v1/tarball/layer.go

+3-3
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@ import (
2323
"sync"
2424

2525
"github.com/containerd/stargz-snapshotter/estargz"
26+
"github.com/google/go-containerregistry/internal/and"
27+
gestargz "github.com/google/go-containerregistry/internal/estargz"
28+
ggzip "github.com/google/go-containerregistry/internal/gzip"
2629
v1 "github.com/google/go-containerregistry/pkg/v1"
27-
"github.com/google/go-containerregistry/pkg/v1/internal/and"
28-
gestargz "github.com/google/go-containerregistry/pkg/v1/internal/estargz"
29-
ggzip "github.com/google/go-containerregistry/pkg/v1/internal/gzip"
3030
"github.com/google/go-containerregistry/pkg/v1/types"
3131
)
3232

pkg/v1/tarball/layer_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ import (
2323
"testing"
2424

2525
"github.com/containerd/stargz-snapshotter/estargz"
26-
"github.com/google/go-containerregistry/pkg/internal/compare"
26+
"github.com/google/go-containerregistry/internal/compare"
2727
"github.com/google/go-containerregistry/pkg/v1/validate"
2828
)
2929

pkg/v1/tarball/write_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ import (
2525
"strings"
2626
"testing"
2727

28-
"github.com/google/go-containerregistry/pkg/internal/compare"
28+
"github.com/google/go-containerregistry/internal/compare"
2929
"github.com/google/go-containerregistry/pkg/name"
3030
v1 "github.com/google/go-containerregistry/pkg/v1"
3131
"github.com/google/go-containerregistry/pkg/v1/mutate"

0 commit comments

Comments
 (0)