onyo.lib.differs module

onyo.lib.differs.differ_modify_asset(repo, operands)[source]

Differ for the ‘modify_assets’ operation.

Not intended for direct use. It is called from an Operator, which is assumed to have validated all input passed to this (trusting) differ.

Yields the diff of the operation line-by-line.

Parameters:
  • repo (OnyoRepo) – Onyo repository to operate on.

  • operands (tuple[Item, Item]) – Items of the original and updated asset.

Return type:

Generator[str, None, None]

onyo.lib.differs.differ_move_asset(repo, operands)[source]

Differ for the ‘move_assets’ operation.

Not intended for direct use. It is called from an Operator, which is assumed to have validated all input passed to this (trusting) differ.

Yields the diff of the operation line-by-line.

Parameters:
  • repo (OnyoRepo) – Onyo repository to operate on.

  • operands (tuple[Path, Path]) – Absolute Paths of the source and destination parent.

Return type:

Generator[str, None, None]

onyo.lib.differs.differ_move_directory(repo, operands)[source]

Differ for the ‘move_directories’ operation.

Not intended for direct use. It is called from an Operator, which is assumed to have validated all input passed to this (trusting) differ.

Yields the diff of the operation line-by-line.

Parameters:
  • repo (OnyoRepo) – Onyo repository to operate on.

  • operands (tuple[Path, Path]) – Absolute Paths of the source and destination parent.

Return type:

Generator[str, None, None]

onyo.lib.differs.differ_new_asset(repo, operands)[source]

Differ for the ‘new_assets’ operation.

Not intended for direct use. It is called from an Operator, which is assumed to have validated all input passed to this (trusting) differ.

Yields the diff of the operation line-by-line.

Parameters:
  • repo (OnyoRepo) – Onyo repository to operate on.

  • operands (tuple[Item]) – Asset to create.

Return type:

Generator[str, None, None]

onyo.lib.differs.differ_new_directory(repo, operands)[source]

Differ for the ‘new_directories’ operation.

Not intended for direct use. It is called from an Operator, which is assumed to have validated all input passed to this (trusting) differ.

Yields the diff of the operation line-by-line.

Parameters:
  • repo (OnyoRepo) – Onyo repository to operate on.

  • operands (tuple[Path]) – Absolute Path of directory to create.

Return type:

Generator[str, None, None]

onyo.lib.differs.differ_remove_asset(repo, operands)[source]

Differ for the ‘remove_assets’ operation.

Not intended for direct use. It is called from an Operator, which is assumed to have validated all input passed to this (trusting) differ.

Yields the diff of the operation line-by-line.

Parameters:
  • repo (OnyoRepo) – Onyo repository to operate on.

  • operands (tuple[Item]) – Asset to remove.

Return type:

Generator[str, None, None]

onyo.lib.differs.differ_remove_directory(repo, operands)[source]

Differ for the ‘remove_directories’ operation.

Not intended for direct use. It is called from an Operator, which is assumed to have validated all input passed to this (trusting) differ.

Yields the diff of the operation line-by-line.

Parameters:
  • repo (OnyoRepo) – Onyo repository to operate on.

  • operands (tuple[Item]) – Directory to remove.

Return type:

Generator[str, None, None]

onyo.lib.differs.differ_rename_asset(repo, operands)[source]

Differ for the ‘rename_assets’ operation.

Not intended for direct use. It is called from an Operator, which is assumed to have validated all input passed to this (trusting) differ.

Yields the diff of the operation line-by-line.

Parameters:
  • repo (OnyoRepo) – Onyo repository to operate on.

  • operands (tuple[Path, Path]) – Absolute Paths of the source and destination.

Return type:

Generator[str, None, None]

onyo.lib.differs.differ_rename_directory(repo, operands)[source]

Differ for the ‘rename_directories’ operation.

Not intended for direct use. It is called from an Operator, which is assumed to have validated all input passed to this (trusting) differ.

Yields the diff of the operation line-by-line.

Parameters:
  • repo (OnyoRepo) – Onyo repository to operate on.

  • operands (tuple[Path, Path]) – Absolute Paths of the source and destination.

Return type:

Generator[str, None, None]