@@ -80,7 +80,7 @@ def edit(server_name, new, editor):
8080
8181 if isinstance (server_config , STDIOServerConfig ):
8282 table .add_row ("Command" , server_config .command )
83- table .add_row ("Arguments" , ", " .join (server_config .args ) if server_config .args else "[dim]None[/]" )
83+ table .add_row ("Arguments" , " " .join (server_config .args ) if server_config .args else "[dim]None[/]" )
8484 table .add_row (
8585 "Environment" ,
8686 ", " .join (f"{ k } ={ v } " for k , v in server_config .env .items ()) if server_config .env else "[dim]None[/]" ,
@@ -187,10 +187,10 @@ def interactive_server_edit(server_config) -> Optional[Dict[str, Any]]:
187187 keybindings = {"interrupt" : [{"key" : "escape" }]},
188188 ).execute ()
189189
190- # Arguments as comma -separated string
191- current_args = ", " .join (server_config .args ) if server_config .args else ""
190+ # Arguments as space -separated string
191+ current_args = " " .join (server_config .args ) if server_config .args else ""
192192 answers ["args" ] = inquirer .text (
193- message = "Arguments (comma -separated):" ,
193+ message = "Arguments (space -separated):" ,
194194 default = current_args ,
195195 instruction = "(Leave empty for no arguments)" ,
196196 keybindings = {"interrupt" : [{"key" : "escape" }]},
@@ -237,7 +237,7 @@ def interactive_server_edit(server_config) -> Optional[Dict[str, Any]]:
237237
238238 if isinstance (server_config , STDIOServerConfig ):
239239 console .print (f"Command: [cyan]{ server_config .command } [/] → [cyan]{ answers ['command' ]} [/]" )
240- new_args = [ arg . strip () for arg in answers ["args" ].split ("," ) if arg . strip ()] if answers ["args" ] else []
240+ new_args = answers ["args" ].split () if answers ["args" ] else []
241241 console .print (f"Arguments: [cyan]{ server_config .args } [/] → [cyan]{ new_args } [/]" )
242242
243243 new_env = {}
@@ -298,7 +298,7 @@ def apply_interactive_changes(server_config, interactive_result):
298298
299299 # Parse arguments
300300 if answers ["args" ].strip ():
301- server_config .args = [ arg . strip () for arg in answers ["args" ].split ("," ) if arg . strip ()]
301+ server_config .args = answers ["args" ].split ()
302302 else :
303303 server_config .args = []
304304
@@ -381,9 +381,7 @@ def _create_new_server():
381381 server_config = STDIOServerConfig (
382382 name = server_name ,
383383 command = result ["answers" ]["command" ],
384- args = [arg .strip () for arg in result ["answers" ]["args" ].split ("," ) if arg .strip ()]
385- if result ["answers" ]["args" ]
386- else [],
384+ args = result ["answers" ]["args" ].split () if result ["answers" ]["args" ] else [],
387385 env = {},
388386 )
389387
@@ -462,7 +460,7 @@ def _interactive_new_server_form() -> Optional[Dict[str, Any]]:
462460 ).execute ()
463461
464462 answers ["args" ] = inquirer .text (
465- message = "Arguments (comma -separated):" ,
463+ message = "Arguments (space -separated):" ,
466464 instruction = "(Leave empty for no arguments)" ,
467465 keybindings = {"interrupt" : [{"key" : "escape" }]},
468466 ).execute ()
@@ -497,7 +495,7 @@ def _interactive_new_server_form() -> Optional[Dict[str, Any]]:
497495
498496 if answers ["type" ] == "stdio" :
499497 console .print (f"Command: [cyan]{ answers ['command' ]} [/]" )
500- new_args = [ arg . strip () for arg in answers ["args" ].split ("," ) if arg . strip ()] if answers ["args" ] else []
498+ new_args = answers ["args" ].split () if answers ["args" ] else []
501499 console .print (f"Arguments: [cyan]{ new_args } [/]" )
502500
503501 new_env = {}
0 commit comments