Handle command options with `Gio.Application.add_main_option_entries`
-
Use Gio.Application.add_main_option_entries() to parse arguments.
-
override handle_local_options() to show information, to make sure -v works in flatpak environment.
-
override local_command_line() to check '--' option.
-
disable the flatpak
session-bus
permission, ref the guide line: https://docs.flatpak.org/en/latest/sandbox-permissions.html#d-bus-accessAccess to the entire bus with
--socket=system-bus
or--socket=session-bus
should be avoided, unless the application is a development tool. -
Implement the
--tab
option and handle multiple commands from options.
Improves !118 (merged)
Closes #276
Implements #206
Screenshot
Open multiple commands without a new tab:
Open multiple commands with a new tab:
Edited by Luo Yi