maxwelllink.cli.mxl_clean module

Clean local MaxwellLink workspace artifacts created by mxl-init.

This module provides the implementation behind mxl-clean and mxl clean.

maxwelllink.cli.mxl_clean.clean_workspace(destination, payload_root, force=False)[source]

Clean managed workspace files and symlinks from a destination folder.

Parameters:
  • destination (pathlib.Path) – Workspace directory to clean.

  • payload_root (pathlib.Path) – Root directory containing installed payload targets.

  • force (bool, default=False) – Whether to remove conflicting/modified managed paths.

Raises:
  • FileNotFoundError – If payload_root is invalid.

  • FileExistsError – If conflicting managed paths are found and force is False.

Return type:

None

maxwelllink.cli.mxl_clean.mxl_clean_main(argv=None)[source]

Run the mxl-clean CLI entry point.

Parameters:

argv (list of str or None, default=None) – Optional command-line arguments. When None, uses sys.argv.

Returns:

0 on success, otherwise non-zero on failure.

Return type:

int