'Analyze the contents of the Git, HG, BZR, SVN and CVS ignore file
and extract filenames.
:param body: The contents of the file to analyze.
:return: A list of filenames found.'

def ignore_file(self, body):

    filenames = set()
    for line in body.split('\n'):
        line = line.strip()
        if (line.startswith('#') or (line == '')):
            continue
        line = self.filter_special_character(line)
        if (not line):
            continue
        if (line.startswith('/') or line.startswith('^')):
            line = line[1:]
        if (line.endswith('/') or line.endswith('$')):
            line = line[:(-1)]
        filenames.add(line)
    return filenames
