comparison tools/emboss_5/emboss_single_outputfile_wrapper.pl @ 0:9071e359b9a3

Uploaded
author xuebing
date Fri, 09 Mar 2012 19:37:19 -0500
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:9071e359b9a3
1 #! /usr/bin/perl -w
2 use strict;
3 use File::Copy;
4
5 my $cmd_string = join (" ",@ARGV);
6 my $results = `$cmd_string`;
7 my @files = split("\n",$results);
8 my $fileNameOut = $ARGV[6];
9 my ($drive, $outputDir, $file) = File::Spec->splitpath( $fileNameOut );
10 my $destination = $fileNameOut;
11
12 foreach my $thisLine (@files)
13 {
14 if ($thisLine =~ /Created /)
15 {
16 $thisLine =~ /[\w|\.]+$/;
17 $thisLine =$&;
18 #print "outfile: $thisLine\n";
19 #there is only one file to move, so we can quit after finding it
20 move($drive.$outputDir.$thisLine,$fileNameOut);
21 exit(1);
22 }
23 else
24 {
25 print $thisLine,"\n";
26 }
27 }