spacr.__main__¶
Command-line entry point for python -m spacr.
The module builds and dispatches spaCR’s command-line subcommands. Every window command opens the PySide6 application; with no subcommand it opens on the Home tab.
Copyright © 2025 olafsson lab
Functions¶
|
Return the argparse parser exposing the |
|
CLI entry point; dispatch to the requested spacr subcommand. |
Module Contents¶
- spacr.__main__.build_parser() argparse.ArgumentParser[source]¶
Return the argparse parser exposing the
spacrCLI subcommands.- Returns:
Parser accepting a single positional
commandargument.
- spacr.__main__.main(argv: list[str] | None = None) int[source]¶
CLI entry point; dispatch to the requested spacr subcommand.
- Parameters:
argv – Argument list to parse. When None,
sys.argv[1:]is used.- Returns:
0for the version command; window commands return the Qt launcher’s integer exit status.- Raises:
SystemExit – with code
2when argparse rejects the arguments or a command accepted by the parser has no dispatcher.parser.errornever returns, so there is no exit code to hand back in either case.