On this page
main() function with strictcli for claudewheel CLI.
#claudewheel.cli
#claudewheel.cli
CLI argument parsing, subcommand routing, and launch orchestration.
#_do_uninstall
def _do_uninstall(version: str) -> intDelete an installed Claude Code version binary.
Refuses to delete the version the claude symlink currently points to, since that would break the default claude command. Returns a process exit code.
#_do_reset_options
def _do_reset_options() -> intDelete OPTIONS_FILE so it regenerates from defaults on next run.
Does NOT instantiate ConfigManager -- the next normal run will recreate options.json via _ensure_dir. Idempotent: missing file is not an error.
#_do_show
def _do_show(cfg: object) -> intPrint a git-status-like summary of last_config, segments, theme, and recent dirs.
#_do_launch_sequence
def _do_launch_sequence(cfg: object, selections: dict, extra_flags: list[str] | None=None, interactive: bool=True, metadata: dict[str, dict[str, dict]] | None=None) -> NoneRun health check, hooks, save state, resolve, and exec. Does not return on success.
#_check_resume_session
def _check_resume_session(session_id: str, directory: str) -> NoneIntercept --resume to detect and offer to fix directory renames.
When a session exists under an old encoded path (because the project directory was renamed), this function detects the mismatch and offers to move all sessions to the new path via run_mv.
Returns normally when no interception is needed (session found under current directory, or sessions successfully moved). Calls sys.exit(1) when the session cannot be resumed from here.
#_check_cont_session
def _check_cont_session(directory: str) -> NoneIntercept --cont to detect and offer to fix directory renames.
When the current directory has no sessions but an orphaned project directory exists under the same parent (original cwd no longer on disk), this function offers to move those sessions to the current directory via run_mv.
#_build_app
def _build_app() -> AppBuild the strictcli App with all subcommands registered.
#main
def main() -> NoneCLI entry point that parses arguments and dispatches to subcommands or the TUI.