Skip to content

Commit 801fcc3

Browse files
authored
Fix docs to reflect new codegate workspace subcommand (#635)
this was introduced by #633 Signed-off-by: Juan Antonio Osorio <ozz@stacklok.com>
1 parent eddccbb commit 801fcc3

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

src/codegate/pipeline/cli/commands.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -63,11 +63,11 @@ async def _add_workspace(self, args: List[str]) -> str:
6363
Add a workspace
6464
"""
6565
if args is None or len(args) == 0:
66-
return "Please provide a name. Use `codegate-workspace add your_workspace_name`"
66+
return "Please provide a name. Use `codegate workspace add your_workspace_name`"
6767

6868
new_workspace_name = args[0]
6969
if not new_workspace_name:
70-
return "Please provide a name. Use `codegate-workspace add your_workspace_name`"
70+
return "Please provide a name. Use `codegate workspace add your_workspace_name`"
7171

7272
workspace_created = await self.workspace_crud.add_workspace(new_workspace_name)
7373
if not workspace_created:
@@ -83,17 +83,17 @@ async def _activate_workspace(self, args: List[str]) -> str:
8383
Activate a workspace
8484
"""
8585
if args is None or len(args) == 0:
86-
return "Please provide a name. Use `codegate-workspace activate workspace_name`"
86+
return "Please provide a name. Use `codegate workspace activate workspace_name`"
8787

8888
workspace_name = args[0]
8989
if not workspace_name:
90-
return "Please provide a name. Use `codegate-workspace activate workspace_name`"
90+
return "Please provide a name. Use `codegate workspace activate workspace_name`"
9191

9292
was_activated = await self.workspace_crud.activate_workspace(workspace_name)
9393
if not was_activated:
9494
return (
9595
f"Workspace **{workspace_name}** does not exist or was already active. "
96-
f"Use `codegate-workspace add {workspace_name}` to add it"
96+
f"Use `codegate workspace add {workspace_name}` to add it"
9797
)
9898
return f"Workspace **{workspace_name}** has been activated"
9999

tests/pipeline/workspace/test_workspace.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,9 +54,9 @@ async def test_list_workspaces(mock_workspaces, expected_output):
5454
"args, existing_workspaces, expected_message",
5555
[
5656
# Case 1: No workspace name provided
57-
([], [], "Please provide a name. Use `codegate-workspace add your_workspace_name`"),
57+
([], [], "Please provide a name. Use `codegate workspace add your_workspace_name`"),
5858
# Case 2: Workspace name is empty string
59-
([""], [], "Please provide a name. Use `codegate-workspace add your_workspace_name`"),
59+
([""], [], "Please provide a name. Use `codegate workspace add your_workspace_name`"),
6060
# Case 3: Successful add
6161
(["myworkspace"], [], "Workspace **myworkspace** has been added"),
6262
],

0 commit comments

Comments
 (0)