Mercurial > repos > mkh > ips5
annotate interproscan5/create_index.py @ 3:74cf3f49f10c draft
Better HTML index.
author | mkh |
---|---|
date | Tue, 02 Feb 2016 12:27:19 -0500 |
parents | fe8e43a26870 |
children |
rev | line source |
---|---|
0 | 1 #!/usr/bin/env python |
2 | |
3 import os | |
4 import sys | |
5 | |
6 o = open(sys.argv[1], 'w+') | |
7 | |
8 o.write('<html> <body> <h1> InterProScan result summary page </h1> <ul>') | |
9 | |
10 for filename in [f for f in os.listdir(sys.argv[2]) if os.path.isfile(os.path.join(sys.argv[2], f))]: | |
11 o.write('<li><a href="%s"> %s </a></li>' % (filename, os.path.splitext(filename)[0])) | |
12 | |
13 o.write('</ul></body></html>') | |
14 o.close() |