From f5223a2a3869bdedb1d667519ec99a491e7d95bc Mon Sep 17 00:00:00 2001 From: Herve ESTEGUET Date: Wed, 15 May 2024 10:00:28 +0200 Subject: [PATCH] Rename module to jfrog-cli-platform-services --- CONTRIBUTING.md | 2 +- PULL_REQUEST_TEMPLATE.md | 4 ++-- README.md | 6 +++--- cli/cli.go | 8 ++++---- commands/add_secret_cmd.go | 2 +- commands/add_secret_cmd_test.go | 2 +- commands/commands_commons.go | 2 +- commands/commands_commons_test.go | 2 +- commands/deploy_cmd.go | 2 +- commands/deploy_cmd_test.go | 2 +- commands/dry_run_cmd.go | 2 +- commands/dry_run_cmd_test.go | 2 +- commands/execute_cmd.go | 2 +- commands/execute_cmd_test.go | 2 +- commands/init_cmd.go | 2 +- commands/init_cmd_test.go | 2 +- commands/list_cmd.go | 2 +- commands/list_cmd_test.go | 2 +- commands/list_event_cmd.go | 2 +- commands/list_event_cmd_test.go | 2 +- commands/remove_cmd.go | 2 +- commands/remove_cmd_test.go | 2 +- go.mod | 2 +- main.go | 4 ++-- 24 files changed, 31 insertions(+), 31 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index e470744..6ad39ef 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -14,7 +14,7 @@ Welcome to the contribution guide for our project! We appreciate your interest i To run a command locally, use the following command template: ```sh -go run github.com/jfrog/workers-cli command [options] [arguments...] +go run github.com/jfrog/jfrog-cli-platform-services command [options] [arguments...] ``` --- diff --git a/PULL_REQUEST_TEMPLATE.md b/PULL_REQUEST_TEMPLATE.md index 545cf8b..01392bd 100644 --- a/PULL_REQUEST_TEMPLATE.md +++ b/PULL_REQUEST_TEMPLATE.md @@ -1,8 +1,8 @@ - [ ] The pull request is targeting the `main` branch. - [ ] The code has been validated to compile successfully by running `go vet ./...`. - [ ] The code has been formatted properly using `go fmt ./...`. -- [ ] All [static analysis checks](https://github.com/jfrog/workers-cli/actions/workflows/analysis.yml) passed. -- [ ] All [tests](https://github.com/jfrog/workers-cli/actions/workflows/unit-tests.yml) have passed. If this feature is not already covered by the tests, new tests have been added. +- [ ] All [static analysis checks](https://github.com/jfrog/jfrog-cli-platform-services/actions/workflows/analysis.yml) passed. +- [ ] All [tests](https://github.com/jfrog/jfrog-cli-platform-services/actions/workflows/unit-tests.yml) have passed. If this feature is not already covered by the tests, new tests have been added. - [ ] All changes are detailed at the description. if not already covered at [JFrog Documentation](https://github.com/jfrog/documentation), new documentation have been added. ----- \ No newline at end of file diff --git a/README.md b/README.md index 9b36f61..d2c7396 100644 --- a/README.md +++ b/README.md @@ -1,17 +1,17 @@
-# jfrog-workers-cli +# jfrog-cli-platform-services [![Scanned by Frogbot](https://raw.github.com/jfrog/frogbot/master/images/frogbot-badge.svg)](https://github.com/jfrog/frogbot#readme)
| Branch | Status | |:------:|:--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------:| -| main | [![Test](https://github.com/jfrog/workers-cli/actions/workflows/unit-tests.yml/badge.svg?branch=main)](https://github.com/jfrog/workers-cli/actions/workflows/unit-tests.yml?query=branch%main) [![Static Analysis](https://github.com/jfrog/workers-cli/actions/workflows/analysis.yml/badge.svg?branch=main)](https://github.com/jfrog/workers-cli/actions/workflows/analysis.yml) | +| main | [![Test](https://github.com/jfrog/jfrog-cli-platform-services/actions/workflows/unit-tests.yml/badge.svg?branch=main)](https://github.com/jfrog/jfrog-cli-platform-services/actions/workflows/unit-tests.yml?query=branch%main) [![Static Analysis](https://github.com/jfrog/jfrog-cli-platform-services/actions/workflows/analysis.yml/badge.svg?branch=main)](https://github.com/jfrog/jfrog-cli-platform-services/actions/workflows/analysis.yml) | ## General -**jfrog-workers-cli** is a Go module that enable jfrog workers commands in the [JFrog CLI](https://docs.jfrog-applications.jfrog.io/jfrog-applications/jfrog-cli). This module is an Embedded JFrog CLI Plugin and is referenced as a Go module within the [JFrog CLI codebase](https://github.com/jfrog/jfrog-cli). +**jfrog-cli-platform-services** is a Go module that enable jfrog workers commands in the [JFrog CLI](https://docs.jfrog-applications.jfrog.io/jfrog-applications/jfrog-cli). This module is an Embedded JFrog CLI Plugin and is referenced as a Go module within the [JFrog CLI codebase](https://github.com/jfrog/jfrog-cli). ## 🫱🏻‍🫲🏼 Contributions diff --git a/cli/cli.go b/cli/cli.go index 322723c..8f53da4 100644 --- a/cli/cli.go +++ b/cli/cli.go @@ -2,19 +2,19 @@ package cli import ( "github.com/jfrog/jfrog-cli-core/v2/plugins/components" - "github.com/jfrog/workers-cli/commands" + "github.com/jfrog/jfrog-cli-platform-services/commands" ) -func GetApp() components.App { +func GetWorkerApp() components.App { app := components.App{} app.Name = "worker" app.Description = "Tools for managing workers" app.Version = "v1.0.0" - app.Commands = getCommands() + app.Commands = getWorkerCommands() return app } -func getCommands() []components.Command { +func getWorkerCommands() []components.Command { return []components.Command{ commands.GetInitCommand(), commands.GetDryRunCommand(), diff --git a/commands/add_secret_cmd.go b/commands/add_secret_cmd.go index e9d096b..1a315b8 100644 --- a/commands/add_secret_cmd.go +++ b/commands/add_secret_cmd.go @@ -9,7 +9,7 @@ import ( "github.com/jfrog/jfrog-cli-core/v2/utils/ioutils" "github.com/jfrog/jfrog-client-go/utils/log" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" ) type addSecretCommand struct { diff --git a/commands/add_secret_cmd_test.go b/commands/add_secret_cmd_test.go index c38513e..ae660f5 100644 --- a/commands/add_secret_cmd_test.go +++ b/commands/add_secret_cmd_test.go @@ -8,7 +8,7 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" ) type addSecretAssertFunc func(t *testing.T, manifestBefore, manifestAfter *model.Manifest) diff --git a/commands/commands_commons.go b/commands/commands_commons.go index 690e226..07cc84d 100644 --- a/commands/commands_commons.go +++ b/commands/commands_commons.go @@ -18,7 +18,7 @@ import ( "github.com/jfrog/jfrog-client-go/utils" "github.com/jfrog/jfrog-client-go/utils/log" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" ) // Useful to capture output in tests diff --git a/commands/commands_commons_test.go b/commands/commands_commons_test.go index da827b0..bc9b634 100644 --- a/commands/commands_commons_test.go +++ b/commands/commands_commons_test.go @@ -15,7 +15,7 @@ import ( "github.com/stretchr/testify/require" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" ) const secretPassword = "P@ssw0rd!" diff --git a/commands/deploy_cmd.go b/commands/deploy_cmd.go index a9a20b2..c8af1f6 100644 --- a/commands/deploy_cmd.go +++ b/commands/deploy_cmd.go @@ -9,7 +9,7 @@ import ( "github.com/jfrog/jfrog-cli-core/v2/plugins/components" "github.com/jfrog/jfrog-client-go/utils/log" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" ) type deployRequest struct { diff --git a/commands/deploy_cmd_test.go b/commands/deploy_cmd_test.go index a8bddec..39e46b2 100644 --- a/commands/deploy_cmd_test.go +++ b/commands/deploy_cmd_test.go @@ -16,7 +16,7 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" ) func TestDeployCommand(t *testing.T) { diff --git a/commands/dry_run_cmd.go b/commands/dry_run_cmd.go index ec82a65..013e0bd 100644 --- a/commands/dry_run_cmd.go +++ b/commands/dry_run_cmd.go @@ -9,7 +9,7 @@ import ( plugins_common "github.com/jfrog/jfrog-cli-core/v2/plugins/common" "github.com/jfrog/jfrog-cli-core/v2/plugins/components" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" ) type dryRunHandler struct { diff --git a/commands/dry_run_cmd_test.go b/commands/dry_run_cmd_test.go index 6048c71..c4a8694 100644 --- a/commands/dry_run_cmd_test.go +++ b/commands/dry_run_cmd_test.go @@ -17,7 +17,7 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" ) type dryRunAssertFunc func(t *testing.T, stdOutput []byte, err error, serverBehavior *dryRunServerStubBehavior) diff --git a/commands/execute_cmd.go b/commands/execute_cmd.go index d453d33..344ec1b 100644 --- a/commands/execute_cmd.go +++ b/commands/execute_cmd.go @@ -10,7 +10,7 @@ import ( plugins_common "github.com/jfrog/jfrog-cli-core/v2/plugins/common" "github.com/jfrog/jfrog-cli-core/v2/plugins/components" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" ) func GetExecuteCommand() components.Command { diff --git a/commands/execute_cmd_test.go b/commands/execute_cmd_test.go index 397b56d..909d0ab 100644 --- a/commands/execute_cmd_test.go +++ b/commands/execute_cmd_test.go @@ -17,7 +17,7 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" ) type executeAssertFunc func(t *testing.T, stdOutput []byte, err error, serverBehavior *executeServerStubBehavior) diff --git a/commands/init_cmd.go b/commands/init_cmd.go index 6a19f27..b8e650a 100644 --- a/commands/init_cmd.go +++ b/commands/init_cmd.go @@ -9,7 +9,7 @@ import ( "strings" "text/template" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" "github.com/jfrog/jfrog-cli-core/v2/plugins/components" "github.com/jfrog/jfrog-client-go/utils/log" diff --git a/commands/init_cmd_test.go b/commands/init_cmd_test.go index 47b05bd..c4a6832 100644 --- a/commands/init_cmd_test.go +++ b/commands/init_cmd_test.go @@ -8,7 +8,7 @@ import ( "strings" "testing" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" diff --git a/commands/list_cmd.go b/commands/list_cmd.go index 2825025..b758fef 100644 --- a/commands/list_cmd.go +++ b/commands/list_cmd.go @@ -12,7 +12,7 @@ import ( "github.com/jfrog/jfrog-cli-core/v2/plugins/components" "github.com/jfrog/jfrog-client-go/utils/log" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" ) type getAllResponse struct { diff --git a/commands/list_cmd_test.go b/commands/list_cmd_test.go index ca724cb..4ec844b 100644 --- a/commands/list_cmd_test.go +++ b/commands/list_cmd_test.go @@ -16,7 +16,7 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" ) func TestListCommand(t *testing.T) { diff --git a/commands/list_event_cmd.go b/commands/list_event_cmd.go index e308ee4..4754f26 100644 --- a/commands/list_event_cmd.go +++ b/commands/list_event_cmd.go @@ -6,7 +6,7 @@ import ( plugins_common "github.com/jfrog/jfrog-cli-core/v2/plugins/common" "github.com/jfrog/jfrog-cli-core/v2/plugins/components" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" ) func GetListEventsCommand() components.Command { diff --git a/commands/list_event_cmd_test.go b/commands/list_event_cmd_test.go index 71cfab3..5c28513 100644 --- a/commands/list_event_cmd_test.go +++ b/commands/list_event_cmd_test.go @@ -15,7 +15,7 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" ) func TestListEventCommand(t *testing.T) { diff --git a/commands/remove_cmd.go b/commands/remove_cmd.go index 0f5ab63..61e5adb 100644 --- a/commands/remove_cmd.go +++ b/commands/remove_cmd.go @@ -8,7 +8,7 @@ import ( "github.com/jfrog/jfrog-cli-core/v2/plugins/components" "github.com/jfrog/jfrog-client-go/utils/log" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" ) func GetRemoveCommand() components.Command { diff --git a/commands/remove_cmd_test.go b/commands/remove_cmd_test.go index 058f8de..9300a21 100644 --- a/commands/remove_cmd_test.go +++ b/commands/remove_cmd_test.go @@ -13,7 +13,7 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - "github.com/jfrog/workers-cli/model" + "github.com/jfrog/jfrog-cli-platform-services/model" ) func TestRemoveCommand(t *testing.T) { diff --git a/go.mod b/go.mod index d2a6231..084ee75 100644 --- a/go.mod +++ b/go.mod @@ -1,4 +1,4 @@ -module github.com/jfrog/workers-cli +module github.com/jfrog/jfrog-cli-platform-services require ( github.com/jfrog/jfrog-cli-core/v2 v2.51.0 diff --git a/main.go b/main.go index 688ec68..e755d25 100644 --- a/main.go +++ b/main.go @@ -2,9 +2,9 @@ package main import ( "github.com/jfrog/jfrog-cli-core/v2/plugins" - "github.com/jfrog/workers-cli/cli" + "github.com/jfrog/jfrog-cli-platform-services/cli" ) func main() { - plugins.PluginMain(cli.GetApp()) + plugins.PluginMain(cli.GetWorkerApp()) }