stubber.utils.ignore

Module Contents

Functions

read_exclusion_file(path: Optional[pathlib.Path] = None) → List[str]

Read a .exclusion file to determine which files should not be automatically re-generated

should_ignore(file: str, exclusions: List[str]) → bool

Check if a file matches a line in the exclusion list.

Attributes

log

stubber.utils.ignore.log
stubber.utils.ignore.read_exclusion_file(path: Optional[pathlib.Path] = None) List[str]

Read a .exclusion file to determine which files should not be automatically re-generated in .GitIgnore format

Parameters

path (Optional[pathlib.Path]) –

Return type

List[str]

stubber.utils.ignore.should_ignore(file: str, exclusions: List[str]) bool

Check if a file matches a line in the exclusion list.

Parameters
  • file (str) –

  • exclusions (List[str]) –

Return type

bool