module documentation

Undocumented

Function find​_command Undocumented
Function get​_command​_line​_option Return the value of a command line option (which should include leading dashes, e.g. '--testrunner') from an argument list. Return None if the option wasn't passed or if the argument list couldn't be parsed.
Function get​_random​_secret​_key Return a 50 character random string usable as a SECRET_KEY setting value.
Function handle​_extensions Organize multiple extensions that are separated with commas or passed by using --extension/-e multiple times.
Function is​_ignored​_path Check if the given path should be ignored or not based on matching one of the glob style ignore_patterns.
Function normalize​_path​_patterns Normalize an iterable of glob style patterns based on OS.
Function parse​_apps​_and​_model​_labels No summary
Function popen​_wrapper Friendly wrapper around Popen.
def find_command(cmd, path=None, pathext=None):

Undocumented

def get_command_line_option(argv, option):
Return the value of a command line option (which should include leading dashes, e.g. '--testrunner') from an argument list. Return None if the option wasn't passed or if the argument list couldn't be parsed.
def get_random_secret_key():
Return a 50 character random string usable as a SECRET_KEY setting value.
def handle_extensions(extensions):

Organize multiple extensions that are separated with commas or passed by using --extension/-e multiple times.

For example: running 'django-admin makemessages -e js,txt -e xhtml -a' would result in an extension list: ['.js', '.txt', '.xhtml']

>>> handle_extensions(['.html', 'html,js,py,py,py,.py', 'py,.py'])
{'.html', '.js', '.py'}
>>> handle_extensions(['.html, txt,.tpl'])
{'.html', '.tpl', '.txt'}
def is_ignored_path(path, ignore_patterns):
Check if the given path should be ignored or not based on matching one of the glob style ignore_patterns.
def normalize_path_patterns(patterns):
Normalize an iterable of glob style patterns based on OS.
def parse_apps_and_model_labels(labels):

Parse a list of "app_label.ModelName" or "app_label" strings into actual objects and return a two-element tuple:

(set of model classes, set of app_configs).

Raise a CommandError if some specified models or apps don't exist.

def popen_wrapper(args, stdout_encoding='utf-8'):

Friendly wrapper around Popen.

Return stdout output, stderr output, and OS status code.