Module utils

Module utils 

Source

Statics§

CONFIGURATION_EXTENSIONS
GENERATED_NAMES_EXTENSIONS

Functions§

is_binary
Checks if a file is binary or not by checking if it contains a null byte. this is based on https://git.kernel.org/pub/scm/git/git.git/tree/xdiff-interface.c?id=HEAD#n198
is_configuration
Checks if a file is a configuration file by checking if it has a configuration extension.
is_documentation
Checks if a file is documentation by checking if it matches any of the documentation rules.
is_dotfile
Checks if a file is a dotfile by checking if it starts with a dot.
is_generated
Checks if a file is generated by checking it’s extension.
is_vendor
Checks if a file is a vendor file by checking if it matches any of the vendor rules.