@@ -153,7 +153,7 @@ def subcommands(self) -> Dict[str, Callable[[List[str]], Awaitable[str]]]:
153
153
"list" : self ._list_workspaces ,
154
154
"add" : self ._add_workspace ,
155
155
"activate" : self ._activate_workspace ,
156
- "remove " : self ._remove_workspace ,
156
+ "archive " : self ._archive_workspace ,
157
157
"rename" : self ._rename_workspace ,
158
158
"list-archived" : self ._list_archived_workspaces ,
159
159
"restore" : self ._restore_workspace ,
@@ -249,16 +249,16 @@ async def _activate_workspace(self, flags: Dict[str, str], args: List[str]) -> s
249
249
return "An error occurred while activating the workspace"
250
250
return f"Workspace **{ workspace_name } ** has been activated"
251
251
252
- async def _remove_workspace (self , flags : Dict [str , str ], args : List [str ]) -> str :
252
+ async def _archive_workspace (self , flags : Dict [str , str ], args : List [str ]) -> str :
253
253
"""
254
254
Remove a workspace
255
255
"""
256
256
if args is None or len (args ) == 0 :
257
- return "Please provide a name. Use `codegate workspace remove workspace_name`"
257
+ return "Please provide a name. Use `codegate workspace archive workspace_name`"
258
258
259
259
workspace_name = args [0 ]
260
260
if not workspace_name :
261
- return "Please provide a name. Use `codegate workspace remove workspace_name`"
261
+ return "Please provide a name. Use `codegate workspace archive workspace_name`"
262
262
263
263
try :
264
264
await self .workspace_crud .soft_delete_workspace (workspace_name )
@@ -267,8 +267,8 @@ async def _remove_workspace(self, flags: Dict[str, str], args: List[str]) -> str
267
267
except crud .WorkspaceCrudError as e :
268
268
return str (e )
269
269
except Exception :
270
- return "An error occurred while removing the workspace"
271
- return f"Workspace **{ workspace_name } ** has been removed "
270
+ return "An error occurred while archiving the workspace"
271
+ return f"Workspace **{ workspace_name } ** has been archived "
272
272
273
273
async def _list_archived_workspaces (self , flags : Dict [str , str ], args : List [str ]) -> str :
274
274
"""
@@ -337,7 +337,7 @@ def help(self) -> str:
337
337
"- `activate`: Activate a workspace\n \n "
338
338
" - *args*:\n \n "
339
339
" - `workspace_name`\n \n "
340
- "- `remove `: Remove a workspace\n \n "
340
+ "- `archive `: Archive a workspace\n \n "
341
341
" - *args*:\n \n "
342
342
" - `workspace_name`\n \n "
343
343
"- `rename`: Rename a workspace\n \n "
0 commit comments