'Parse each git command and make a Command object for each'

def parse_commands(self):

    self.commands = []
    for file in self.files_to_parse:
        soup = BeautifulSoup(open(file), 'html.parser')
        name_h2 = soup.find('h2', {'id': '_name'})
        if (not name_h2):
            continue
        description_p = name_h2.findNext('p')
        if (not description_p):
            continue
        description = description_p.getText()
        (command_name, description) = description.split('    -    ')
        command = Command(command_name, description, file.replace('download/', ''))
        synopsis_h2 = soup.find('h2', {'id': '_synopsis'})
        if synopsis_h2:
            usage_pre = synopsis_h2.findNext('pre')
            if usage_pre:
                usage = usage_pre.getText()
                command.usage = usage
        options_h2s = soup.find_all('h2')
        for options_h2 in options_h2s:
            if (options_h2.getText() != 'OPTIONS'):
                continue
            options = []
            for option_h2_child in options_h2.parent.find_all():
                if (option_h2_child.name == 'dt'):
                    options.append(option_h2_child.getText())
                elif (option_h2_child.name == 'p'):
                    description = option_h2_child.getText()
                    for option in options:
                        command_name_with_option = '{}    {}'.format(command_name, option)
                        command_with_option = Command(command_name_with_option, description, file.replace('download/', ''))
                        self.commands.append(command_with_option)
                    options = []
        self.commands.append(command)
