def parse_requirements(file_name):
requirements = []<EOL>with open(file_name, '<STR_LIT:r>') as f:<EOL><INDENT>for line in f:<EOL><INDENT>if re.match(r'<STR_LIT>', line): continue<EOL>if re.match(r'<STR_LIT>', line):<EOL><INDENT>requirements.append(re.sub(r'<STR_LIT>',r'<STR_LIT>', line).strip())<EOL><DEDENT>elif re.match(r'<STR_LIT>', line):<EOL><INDENT>pass<EOL><DEDENT>else:<EOL><INDENT>requirements.append(line.strip())<EOL><DEDENT><DEDENT><DEDENT>return requirements<EOL>
from:
    http://cburgmer.posterous.com/pip-requirementstxt-and-setuppy