Skip to content

Commit

Permalink
symlink latest tree
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewjpage committed May 9, 2012
1 parent 58e7a2d commit 23492cc
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions run_gubbins.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ def create_pairwise_newick_tree(sequence_names, output_filename):
parser.add_argument('--outgroup', '-o', help='Outgroup name for rerooting')
parser.add_argument('--starting_tree', '-s', help='Starting tree')
parser.add_argument('--verbose', '-v', action='count', help='Turn on debugging')
parser.add_argument('--tree_builder', '-t', help='Application to use for tree building (raxml, fasttree), default is to use FastTree for 1st iteration and RAxML for rest', default = "hybrid")
parser.add_argument('--tree_builder', '-t', help='Application to use for tree building (raxml, fasttree, hybrid), default RAxML', default = "raxml")
parser.add_argument('--iterations', '-i', help='Maximum No. of iterations, default is 5', type=int, default = 5)
args = parser.parse_args()

Expand Down Expand Up @@ -202,7 +202,11 @@ def create_pairwise_newick_tree(sequence_names, output_filename):
subprocess.call(tree_building_command, shell=True)

reroot_tree(str(current_tree_name), args.outgroup)


if(os.path.exists("latest.tre")):
remove("latest.tre")
os.symlink(str(current_tree_name), "latest.tre")

if args.verbose > 0:
print gubbins_command
subprocess.call(gubbins_command, shell=True)
Expand Down

0 comments on commit 23492cc

Please sign in to comment.