Commits

Casey Dunn committed 6d279d9 Merge

Merged in beroe/phylogeneticbiology/beroe/proposed-reorganization-using-the-__doc_-1371081864817 (pull request #1)

Proposed reorganization, using the __doc__ docstring instead of the variable usage in shorten_headers.py (edited online with Bitbucket)

Comments (0)

Files changed (1)

scripts/shorten_headers.py

 #! /usr/bin/env python
-import re, sys
-
-usage = """
+"""
 Shortens the header of NCBI fasta files to Genus_species_gi
 
 usage:
 
 
 """
+import re, sys
 
 def shorten_headers( in_name ):
 	infile = open( in_name, "rU" )
 
 if __name__ == "__main__":
 	if len(sys.argv) < 2:
-		print usage
+		print __doc__
 		sys.exit( 0 )
 	in_name = sys.argv[1]
 	print shorten_headers( in_name )