venvmod.tools module

Regroups tool for the package.

venvmod.tools.check_raise(condition: bool, exception_type: Exception, message: str)[source]

Chack if a condition is True to raise

Parameters:
  • condition (bool) – Condition to be True to raise

  • exception_type (Exception) – Exception to raise

  • message (str) – Message for the exception

Raises:

exception_type – _description_

venvmod.tools.get_shell_command() str[source]

Gets current shell name.

Returns:

shell command

Return type:

str

venvmod.tools.remove_duplicates(input_list: List) List[source]

Removes duplicate values in a list.

Parameters:

input_list (List) – Input list.

Returns:

Output list.

Return type:

List

venvmod.tools.get_std_name(name: str) str[source]
Transform a name in standard name:
  • lower case

  • ‘_’ -> ‘-’

Parameters:

name (str) – input name

Returns:

standardized name

Return type:

str