Skip to content

Commit 9d9cafa

Browse files
committed
Move the rest of internal to pkg
Signed-off-by: David Gageot <david.gageot@docker.com>
1 parent 428da52 commit 9d9cafa

36 files changed

Lines changed: 33 additions & 33 deletions

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ RUN --mount=type=cache,target=/root/.cache,id=docker-ai-$TARGETPLATFORM \
2929
--mount=type=secret,id=telemetry_endpoint,env=TELEMETRY_ENDPOINT \
3030
--mount=type=secret,id=telemetry_header,env=TELEMETRY_HEADER <<EOT
3131
set -ex
32-
xx-go build -trimpath -ldflags "-s -w -X 'github.com/docker/cagent/cmd/root.Version=$GIT_TAG' -X 'github.com/docker/cagent/cmd/root.Commit=$GIT_COMMIT' -X 'github.com/docker/cagent/cmd/root.BuildTime=$BUILD_DATE' -X 'github.com/docker/cagent/internal/telemetry.TelemetryEndpoint=$TELEMETRY_ENDPOINT' -X 'github.com/docker/cagent/internal/telemetry.TelemetryAPIKey=$TELEMETRY_API_KEY' -X 'github.com/docker/cagent/internal/telemetry.TelemetryHeader=$TELEMETRY_HEADER'" -o /binaries/cagent-$TARGETOS-$TARGETARCH .
32+
xx-go build -trimpath -ldflags "-s -w -X 'github.com/docker/cagent/cmd/root.Version=$GIT_TAG' -X 'github.com/docker/cagent/cmd/root.Commit=$GIT_COMMIT' -X 'github.com/docker/cagent/cmd/root.BuildTime=$BUILD_DATE' -X 'github.com/docker/cagent/pkg/telemetry.TelemetryEndpoint=$TELEMETRY_ENDPOINT' -X 'github.com/docker/cagent/pkg/telemetry.TelemetryAPIKey=$TELEMETRY_API_KEY' -X 'github.com/docker/cagent/pkg/telemetry.TelemetryHeader=$TELEMETRY_HEADER'" -o /binaries/cagent-$TARGETOS-$TARGETARCH .
3333
file /binaries/cagent-$TARGETos-$TARGETARCH
3434
xx-verify --static /binaries/cagent-$TARGETOS-$TARGETARCH
3535
if [ "$TARGETOS" = "windows" ]; then

Taskfile.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ vars:
1212
sh: date -u +"%Y-%m-%dT%H:%M:%SZ"
1313
GO_SOURCES: "**/*.go"
1414
BUILD_ARGS: '--build-arg GIT_TAG="{{.GIT_TAG}}" --build-arg GIT_COMMIT="{{.GIT_COMMIT}}" --build-arg BUILD_DATE="{{.BUILD_DATE}}" --secret id=telemetry_api_key,env=TELEMETRY_API_KEY --secret id=telemetry_endpoint,env=TELEMETRY_ENDPOINT --secret id=telemetry_header,env=TELEMETRY_HEADER'
15-
LDFLAGS: '-X "github.com/docker/cagent/internal/version.Version={{.GIT_TAG}}" -X "github.com/docker/cagent/internal/version.Commit={{.GIT_COMMIT}}" -X "github.com/docker/cagent/internal/version.BuildTime={{.BUILD_DATE}}" -X "github.com/docker/cagent/internal/telemetry.TelemetryEndpoint={{.TELEMETRY_ENDPOINT}}" -X "github.com/docker/cagent/internal/telemetry.TelemetryAPIKey={{.TELEMETRY_API_KEY}}" -X "github.com/docker/cagent/internal/telemetry.TelemetryHeader={{.TELEMETRY_HEADER}}"'
15+
LDFLAGS: '-X "github.com/docker/cagent/pkg/version.Version={{.GIT_TAG}}" -X "github.com/docker/cagent/pkg/version.Commit={{.GIT_COMMIT}}" -X "github.com/docker/cagent/pkg/version.BuildTime={{.BUILD_DATE}}" -X "github.com/docker/cagent/pkg/telemetry.TelemetryEndpoint={{.TELEMETRY_ENDPOINT}}" -X "github.com/docker/cagent/pkg/telemetry.TelemetryAPIKey={{.TELEMETRY_API_KEY}}" -X "github.com/docker/cagent/pkg/telemetry.TelemetryHeader={{.TELEMETRY_HEADER}}"'
1616

1717
tasks:
1818
default:

cmd/root/api.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,11 @@ import (
88

99
"github.com/spf13/cobra"
1010

11-
"github.com/docker/cagent/internal/telemetry"
1211
"github.com/docker/cagent/pkg/config"
1312
"github.com/docker/cagent/pkg/server"
1413
"github.com/docker/cagent/pkg/session"
1514
"github.com/docker/cagent/pkg/teamloader"
15+
"github.com/docker/cagent/pkg/telemetry"
1616
)
1717

1818
var (

cmd/root/build.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ package root
33
import (
44
"github.com/spf13/cobra"
55

6-
"github.com/docker/cagent/internal/telemetry"
76
"github.com/docker/cagent/pkg/oci"
7+
"github.com/docker/cagent/pkg/telemetry"
88
)
99

1010
var (

cmd/root/catalog.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import (
1010
"text/tabwriter"
1111
"time"
1212

13-
"github.com/docker/cagent/internal/telemetry"
13+
"github.com/docker/cagent/pkg/telemetry"
1414
"github.com/spf13/cobra"
1515
)
1616

cmd/root/eval.go

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

66
"github.com/spf13/cobra"
77

8-
"github.com/docker/cagent/internal/telemetry"
98
"github.com/docker/cagent/pkg/evaluation"
109
"github.com/docker/cagent/pkg/teamloader"
10+
"github.com/docker/cagent/pkg/telemetry"
1111
)
1212

1313
func NewEvalCmd() *cobra.Command {

cmd/root/feedback.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ package root
33
import (
44
"fmt"
55

6-
"github.com/docker/cagent/internal/telemetry"
6+
"github.com/docker/cagent/pkg/telemetry"
77
"github.com/spf13/cobra"
88
)
99

cmd/root/new.go

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

99
"github.com/spf13/cobra"
1010

11-
"github.com/docker/cagent/internal/creator"
12-
"github.com/docker/cagent/internal/telemetry"
11+
"github.com/docker/cagent/pkg/creator"
1312
"github.com/docker/cagent/pkg/runtime"
13+
"github.com/docker/cagent/pkg/telemetry"
1414
)
1515

1616
var (

cmd/root/pull.go

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

10-
"github.com/docker/cagent/internal/telemetry"
1110
"github.com/docker/cagent/pkg/remote"
11+
"github.com/docker/cagent/pkg/telemetry"
1212
"github.com/google/go-containerregistry/pkg/crane"
1313
"github.com/spf13/cobra"
1414
)

cmd/root/push.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@ import (
44
"fmt"
55
"log/slog"
66

7-
"github.com/docker/cagent/internal/telemetry"
87
"github.com/docker/cagent/pkg/content"
98
"github.com/docker/cagent/pkg/oci"
109
"github.com/docker/cagent/pkg/remote"
10+
"github.com/docker/cagent/pkg/telemetry"
1111
"github.com/google/go-containerregistry/pkg/crane"
1212
"github.com/spf13/cobra"
1313
)

0 commit comments

Comments
 (0)