From 4fe863b05951d0b1319be9361e68f5e3b49baa40 Mon Sep 17 00:00:00 2001 From: James Ranson Date: Wed, 22 Jan 2025 15:52:57 -0700 Subject: [PATCH] update to latest sdk --- go.mod | 2 +- go.sum | 4 ++-- internal/commands/build.go | 7 ++++--- internal/commands/common.go | 2 +- internal/commands/deploy.go | 2 +- internal/commands/deployment.go | 4 ++-- internal/commands/log.go | 2 +- internal/mock/hathora.go | 2 +- internal/output/text_test.go | 4 ++-- internal/setup/http.go | 2 +- internal/setup/sdk.go | 2 +- internal/shorthand/container_port.go | 2 +- internal/shorthand/container_port_test.go | 2 +- internal/shorthand/env_var.go | 2 +- internal/shorthand/env_var_test.go | 2 +- 15 files changed, 21 insertions(+), 20 deletions(-) diff --git a/go.mod b/go.mod index f21afc0..3b8c1ee 100644 --- a/go.mod +++ b/go.mod @@ -7,7 +7,7 @@ require ( github.com/fatih/color v1.18.0 github.com/h2non/filetype v1.1.3 github.com/hashicorp/go-cleanhttp v0.5.2 - github.com/hathora/cloud-sdk-go v0.0.0-20250113192510-5287840d4e1e + github.com/hathora/cloud-sdk-go/hathoracloud v0.0.0-20250122221419-b680f9dc502e github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00 github.com/stretchr/testify v1.10.0 github.com/urfave/cli/v3 v3.0.0-alpha9 diff --git a/go.sum b/go.sum index a5435f7..5ee0372 100644 --- a/go.sum +++ b/go.sum @@ -10,8 +10,8 @@ github.com/h2non/filetype v1.1.3 h1:FKkx9QbD7HR/zjK1Ia5XiBsq9zdLi5Kf3zGyFTAFkGg= github.com/h2non/filetype v1.1.3/go.mod h1:319b3zT68BvV+WRj7cwy856M2ehB3HqNOt6sy1HndBY= github.com/hashicorp/go-cleanhttp v0.5.2 h1:035FKYIWjmULyFRBKPs8TBQoi0x6d9G4xc9neXJWAZQ= github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48= -github.com/hathora/cloud-sdk-go v0.0.0-20250113192510-5287840d4e1e h1:D4oQBxhB7fyHKuQxPZ2KYx0XiX8x0D/iotMhhtQ83FQ= -github.com/hathora/cloud-sdk-go v0.0.0-20250113192510-5287840d4e1e/go.mod h1:lngVTwPsJ1dWTMysCGzdJe6Z64rK1za9dKy/HinTAXo= +github.com/hathora/cloud-sdk-go/hathoracloud v0.0.0-20250122221419-b680f9dc502e h1:qUMPXUCAO6KUjUsdPdSVRlrzoR/e7g8s40rUKjzWodo= +github.com/hathora/cloud-sdk-go/hathoracloud v0.0.0-20250122221419-b680f9dc502e/go.mod h1:scOHgTK/ylPtgg39LsTpuUlmwop7tsGlLEP7vBd0Tlk= github.com/mattn/go-colorable v0.1.14 h1:9A9LHSqF/7dyVVX6g0U9cwm9pG3kP9gSzcuIPHPsaIE= github.com/mattn/go-colorable v0.1.14/go.mod h1:6LmQG8QLFO4G5z1gPvYEzlUgJ2wF+stgPZH1UqBm1s8= github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY= diff --git a/internal/commands/build.go b/internal/commands/build.go index b1e2079..688a507 100644 --- a/internal/commands/build.go +++ b/internal/commands/build.go @@ -12,15 +12,16 @@ import ( "github.com/urfave/cli/v3" "go.uber.org/zap" + "golang.org/x/sync/errgroup" "github.com/hathora/ci/internal/archive" "github.com/hathora/ci/internal/commands/altsrc" "github.com/hathora/ci/internal/httputil" "github.com/hathora/ci/internal/output" "github.com/hathora/ci/internal/setup" - sdk "github.com/hathora/cloud-sdk-go" - "github.com/hathora/cloud-sdk-go/models/components" - "golang.org/x/sync/errgroup" + + sdk "github.com/hathora/cloud-sdk-go/hathoracloud" + "github.com/hathora/cloud-sdk-go/hathoracloud/models/components" ) type etagPart struct { diff --git a/internal/commands/common.go b/internal/commands/common.go index dabb8fd..6fc23b7 100644 --- a/internal/commands/common.go +++ b/internal/commands/common.go @@ -15,7 +15,7 @@ import ( "go.uber.org/zap" "github.com/hathora/ci/internal/output" - "github.com/hathora/cloud-sdk-go/models/components" + "github.com/hathora/cloud-sdk-go/hathoracloud/models/components" ) var ( diff --git a/internal/commands/deploy.go b/internal/commands/deploy.go index 734977d..336ba31 100644 --- a/internal/commands/deploy.go +++ b/internal/commands/deploy.go @@ -10,7 +10,7 @@ import ( "go.uber.org/zap" "github.com/hathora/ci/internal/shorthand" - "github.com/hathora/cloud-sdk-go/models/components" + "github.com/hathora/cloud-sdk-go/hathoracloud/models/components" ) var Deploy = &cli.Command{ diff --git a/internal/commands/deployment.go b/internal/commands/deployment.go index b7353c3..e5fc15a 100644 --- a/internal/commands/deployment.go +++ b/internal/commands/deployment.go @@ -16,8 +16,8 @@ import ( "github.com/hathora/ci/internal/setup" "github.com/hathora/ci/internal/shorthand" "github.com/hathora/ci/internal/workaround" - sdk "github.com/hathora/cloud-sdk-go" - "github.com/hathora/cloud-sdk-go/models/components" + sdk "github.com/hathora/cloud-sdk-go/hathoracloud" + "github.com/hathora/cloud-sdk-go/hathoracloud/models/components" ) const deploymentFlagEnvVarPrefix = globalFlagEnvVarPrefix + "DEPLOYMENT_" diff --git a/internal/commands/log.go b/internal/commands/log.go index fe31ece..45299c2 100644 --- a/internal/commands/log.go +++ b/internal/commands/log.go @@ -13,7 +13,7 @@ import ( "github.com/hathora/ci/internal/output" "github.com/hathora/ci/internal/setup" "github.com/hathora/ci/internal/workaround" - sdk "github.com/hathora/cloud-sdk-go" + sdk "github.com/hathora/cloud-sdk-go/hathoracloud" ) const logFlagEnvVarPrefix = globalFlagEnvVarPrefix + "LOG_" diff --git a/internal/mock/hathora.go b/internal/mock/hathora.go index ce385c8..0e97f2e 100644 --- a/internal/mock/hathora.go +++ b/internal/mock/hathora.go @@ -8,7 +8,7 @@ import ( "testing" "github.com/hathora/ci/internal/httputil" - sdk "github.com/hathora/cloud-sdk-go" + sdk "github.com/hathora/cloud-sdk-go/hathoracloud" "github.com/stretchr/testify/require" ) diff --git a/internal/output/text_test.go b/internal/output/text_test.go index 4b752ee..7b01132 100644 --- a/internal/output/text_test.go +++ b/internal/output/text_test.go @@ -9,8 +9,8 @@ import ( "github.com/stretchr/testify/assert" "github.com/hathora/ci/internal/commands" - sdk "github.com/hathora/cloud-sdk-go" - "github.com/hathora/cloud-sdk-go/models/components" + sdk "github.com/hathora/cloud-sdk-go/hathoracloud" + "github.com/hathora/cloud-sdk-go/hathoracloud/models/components" ) func Test_DeploymentTextOutput(t *testing.T) { diff --git a/internal/setup/http.go b/internal/setup/http.go index 87d335d..e94c9d3 100644 --- a/internal/setup/http.go +++ b/internal/setup/http.go @@ -4,7 +4,7 @@ import ( "github.com/hashicorp/go-cleanhttp" "github.com/hathora/ci/internal/httputil" - sdk "github.com/hathora/cloud-sdk-go" + sdk "github.com/hathora/cloud-sdk-go/hathoracloud" ) func HTTPClient(loggingVerbosity int) sdk.HTTPClient { diff --git a/internal/setup/sdk.go b/internal/setup/sdk.go index cbd6c7b..0b5cafa 100644 --- a/internal/setup/sdk.go +++ b/internal/setup/sdk.go @@ -1,7 +1,7 @@ package setup import ( - sdk "github.com/hathora/cloud-sdk-go" + sdk "github.com/hathora/cloud-sdk-go/hathoracloud" ) func SDK(token, baseURL string, loggingVerbosity int) *sdk.HathoraCloud { diff --git a/internal/shorthand/container_port.go b/internal/shorthand/container_port.go index 63d986e..23d3b4b 100644 --- a/internal/shorthand/container_port.go +++ b/internal/shorthand/container_port.go @@ -7,7 +7,7 @@ import ( "strconv" "strings" - "github.com/hathora/cloud-sdk-go/models/components" + "github.com/hathora/cloud-sdk-go/hathoracloud/models/components" ) var ( diff --git a/internal/shorthand/container_port_test.go b/internal/shorthand/container_port_test.go index 7b6bba8..c38dc17 100644 --- a/internal/shorthand/container_port_test.go +++ b/internal/shorthand/container_port_test.go @@ -7,7 +7,7 @@ import ( "github.com/stretchr/testify/require" "github.com/hathora/ci/internal/shorthand" - "github.com/hathora/cloud-sdk-go/models/components" + "github.com/hathora/cloud-sdk-go/hathoracloud/models/components" ) func Test_ContainerPortShorthand(t *testing.T) { diff --git a/internal/shorthand/env_var.go b/internal/shorthand/env_var.go index d1452c9..9f22968 100644 --- a/internal/shorthand/env_var.go +++ b/internal/shorthand/env_var.go @@ -5,7 +5,7 @@ import ( "regexp" "strings" - "github.com/hathora/cloud-sdk-go/models/components" + "github.com/hathora/cloud-sdk-go/hathoracloud/models/components" ) func ParseDeploymentEnvVar(s string) (*components.DeploymentConfigV3Env, error) { diff --git a/internal/shorthand/env_var_test.go b/internal/shorthand/env_var_test.go index bedadc1..a762a36 100644 --- a/internal/shorthand/env_var_test.go +++ b/internal/shorthand/env_var_test.go @@ -7,7 +7,7 @@ import ( "github.com/stretchr/testify/require" "github.com/hathora/ci/internal/shorthand" - "github.com/hathora/cloud-sdk-go/models/components" + "github.com/hathora/cloud-sdk-go/hathoracloud/models/components" ) func Test_DeploymentEnvVarShorthand(t *testing.T) {