High-level helper functions
Create a UI appropriate for the current environment and user options.
This will be a graphical UI if Gui.try_get_gui
returns one and we're not in dry-run mode.
Otherwise, it will be an interactive console UI if stderr is a tty.
Otherwise, it will be a batch UI (no progress display).