human
Complete the below
def build_whitespace_split_regex(text):

    ''''Create a regular expression at runtime which should match ignoring the
    addition or deletion of white space or line breaks, unless between commas
    Example:
    .. code-block:: python
    >>> import re
    >>> import salt.utils
    >>> regex = salt.utils.build_whitespace_split_regex(
    ...     """if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ].
then"""
    >>> regex
    \'(?:[\s]+)?if(?:[\s]+)?\[(?:[\s]+)?\-z(?:[\s]+)?\"\$debian\'
    \'\_chroot\"(?:[\s]+)?\](?:[\s]+)?\&\&(?:[\s]+)?\[(?:[\s]+)?\'
    \'\-r(?:[\s]+)?\/etc\/debian\_chroot(?:[\s]+)?\]\;(?:[\s]+)?\'
    \'then(?:[\s]+)?\'
    >>> re.search(
    ...     regex,
    ...     """if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ].
then"""
    <_sre.SRE_Match object at 0xb70639c0>'
    '''
assistant
#Here is the Python program you requested.
    def __build_parts(text):
        lexer = shlex.shlex(text)
        lexer.whitespace_split = True
        lexer.commenters = ''
        if ("'" in text):
            lexer.quotes = '"'
        elif ('"' in text):
            lexer.quotes = "'"
        return list(lexer)
    regex = ''
    for line in text.splitlines():
        parts = [re.escape(s) for s in __build_parts(line)]
        regex += '(?:[\\s]+)?{0}(?:[\\s]+)?'.format('(?:[\\s]+)?'.join(parts))
    return '(?m)^{0}$'.format(regex)