From 6c906a750675910323710b293f939a5f26dadd58 Mon Sep 17 00:00:00 2001 From: gbc dev Date: Fri, 17 Jul 2026 00:27:46 +0200 Subject: main: options-first CLI with --help, and wire up display/boot flags - Rewrite argument handling: the ROM is now the final argument and options precede it (parsed in argv[1..argc-2] so optional-value flags never swallow the ROM). Add grouped --help/-h, unknown-option errors, and clear 'missing value'/'no ROM' diagnostics. - Add --chrome, --palette/--green, and --bios flags; set the display/capture options before the --shot and recording paths so screenshots and recordings honor them. Make --shot dump the composited capture frame. - gbctl: pass the ROM last when spawning the emulator. - gitignore the (copyrighted) bios/ directory; document all new flags. --- gbctl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gbctl') diff --git a/gbctl b/gbctl index 287b16a..b926461 100755 --- a/gbctl +++ b/gbctl @@ -200,7 +200,7 @@ def cmd_spawn(argv): if "TMUX" not in os.environ: die("not inside tmux; gbctl spawn needs a tmux session") - cmd = [BIN, rom, "--sock", sock_path] + emu_args + cmd = [BIN, "--sock", sock_path] + emu_args + [rom] # ROM is the final arg # exec via a shell wrapper so the pane stays around & shows a title shell_cmd = "printf '\\033]2;gbc %s\\007'; exec %s" % ( os.path.basename(rom), " ".join(_shquote(c) for c in cmd)) -- cgit v1.3.1-sl0p