diff mirdeep2/target_spy_wrapper.pl @ 0:5b9519f4b165

Upload first commmit
author nikhil-joshi
date Mon, 19 Sep 2011 19:04:41 -0400
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mirdeep2/target_spy_wrapper.pl	Mon Sep 19 19:04:41 2011 -0400
@@ -0,0 +1,22 @@
+#!/usr/bin/perl
+
+use File::Temp qw/ tempfile tempdir /;
+use File::Copy qw/ copy /;
+use Cwd;
+
+$mirna_file = $ARGV[0];
+$trans_file = $ARGV[1];
+$targets = $ARGV[2];
+
+# do all the dirty work in a temp directory
+$cwd = cwd();
+$tempdir = tempdir(CLEANUP => 1);
+
+copy ("/opt/Bio/galaxy-dist/tools/mirdeep2/target_spy_wrapper.sh", $tempdir);
+chdir ($tempdir);
+
+$ret_ts = `sh target_spy_wrapper.sh $mirna_file $trans_file`;
+if ($ret_ts ne "") {die "TargetSpy error"}
+copy ("targets", $targets);
+
+chdir($cwd);