From 6d75dd088e933b1f13e052514122f479be1ae803 Mon Sep 17 00:00:00 2001 From: daisie_local Date: Wed, 18 Mar 2015 12:43:42 -0700 Subject: [PATCH] default outfile --- converting/gb_to_fasta.pl | 3 +++ 1 file changed, 3 insertions(+) diff --git a/converting/gb_to_fasta.pl b/converting/gb_to_fasta.pl index b635d8e..61d1599 100755 --- a/converting/gb_to_fasta.pl +++ b/converting/gb_to_fasta.pl @@ -24,6 +24,9 @@ } my $gbdata = parse_genbank($gbfile); +if ($outfile eq "") { + $outfile = "$gbfile.fasta"; +} open FH, ">", $outfile or die "couldn't create output file $outfile"; print FH ">" . get_name() . "\n" . get_sequence() . "\n";