Skip to content

Latest commit

 

History

History
83 lines (40 loc) · 2.03 KB

velocitas_lib.templates.md

File metadata and controls

83 lines (40 loc) · 2.03 KB

module velocitas_lib.templates


function copy_templates

copy_templates(
    template_dir: str,
    target_dir: str,
    template_file_mapping: List[CopySpec],
    variables: Dict[str, str]
) → None

Copy templates from the template dir to the target dir.

Args:

  • template_dir (str): Path to the directory containing the template files.
  • target_dir (str): Path to the target directory.
  • template_file_mapping (Dict[str, str]): A mapping of source path to target path.
  • variables (Dict[str, str]): Name to value mapping which will be replaced when parsing the template files.

class CopySpec

Copy specification of a single file or directory.

method __init__

__init__(source_path: str, target_path: Optional[str] = None)

method get_target

get_target() → str

Get the target path of the copy spec.

Returns:

  • str: If a target_path is given explicitly, it will be returned. Otherwise the source_path will be returned.

This file was automatically generated via lazydocs.