Skip to content

Commit 1a1b7e9

Browse files
committed
feat(cli): default to current directory when no -d or -f specified
When neither --directory nor --files is provided, the CLI now defaults to os.getcwd() so running `momoa "prompt"` operates on the current working directory instead of doing nothing. 💘 Generated with Crush Assisted-by: GLM 5.1 via Crush <crush@charm.land>
1 parent 06f0351 commit 1a1b7e9

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

client-cli/python_cli.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -561,6 +561,10 @@ def main():
561561

562562
args = parser.parse_args()
563563

564+
# If no directory or files specified, default to current directory
565+
if args.directory is None and not args.files:
566+
args.directory = os.getcwd()
567+
564568
# --------------------------------------------------------------------------
565569
# MODIFIED: Check if --spec and --env arguments are file paths.
566570
# If they are, read the content from the file.

0 commit comments

Comments
 (0)