changeset 0:6b590f108b48 draft default tip

Uploaded
author alermine
date Fri, 08 Jun 2012 09:47:18 -0400
parents
children
files upload_local_file/upload_local_file.sh upload_local_file/upload_local_file.xml
diffstat 2 files changed, 85 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/upload_local_file/upload_local_file.sh	Fri Jun 08 09:47:18 2012 -0400
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+#################################################################################################
+# Upload_local_file tool for Galaxy                                                             #
+# Allow users to add data in their histories whitout having to upload them through the network  #
+# - Script by Alban Lermine, Institut Curie 2012 -                                              #
+#################################################################################################
+
+
+while getopts "b:o:" optionName; do
+case "$optionName" in
+
+b) INPUT_FILE="$OPTARG";;
+o) DATASET="$OPTARG";;
+
+esac
+done
+
+rm $DATASET
+
+ln -s $INPUT_FILE $DATASET
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/upload_local_file/upload_local_file.xml	Fri Jun 08 09:47:18 2012 -0400
@@ -0,0 +1,64 @@
+<tool id="upload_local_file" name="Upload local file">
+  <description>to current History</description>
+  <command interpreter="bash">upload_local_file.sh -b $file -o $out</command>
+  <inputs>
+    <param name="name" type="text" label="File Name"/>
+    <param name="extension" type="select" label="File type">
+	<option value="bam">Bam</option>
+    	<option value="txt">Text</option>
+	<option value="fastq">Fastq</option>
+	<option value="csfasta">Csfasta</option>
+	<option value="qual">Qual</option>
+	<option value="bed">Bed</option>
+	<option value="gff">Gff</option>
+	<option value="pdf">Pdf</option>
+	<option value="vcf">VCF</option>
+	<option value="sam">Sam</option>
+	<option value="fasta">Fasta</option>
+	<option value="xsq">Xsq</option>
+    </param>
+    <param name="file" type="text" size="30" label="Path to file">
+    <validator type="empty_field" message="You must specify a file path"/>
+    </param>
+    <param name="dbkey" type="genomebuild" label="Genome" />
+  </inputs>
+  <outputs>
+    <data format="bam" name="out" label="${name}.${extension}">
+	<change_format>
+		<when input="extension" value="txt" format="txt" />
+		<when input="extension" value="fastq" format="fastq" />
+		<when input="extension" value="csfasta" format="csfasta" />
+		<when input="extension" value="qual" format="qual" />
+		<when input="extension" value="bed" format="bed" />
+		<when input="extension" value="gff" format="gff" />
+		<when input="extension" value="vcf" format="vcf" />
+		<when input="extension" value="sam" format="sam" />
+		<when input="extension" value="fasta" format="fasta" />
+		<when input="extension" value="pdf" format="pdf" />
+		<when input="extension" value="xsq" format="xsq" />
+	</change_format>
+    </data>
+
+  </outputs>
+  <help>
+.. class:: infomark
+
+**What it does:**
+
+This tool allows users to add data in their histories whitout having to upload them through the network.
+
+------
+
+**Input:**
+
+You must provide a filename whitout the extension (which is provide by file type) and the path to the data on the server. If you don't find the extension of your file, don't panic, just upload it with the text extension, and then search for the good format by clicking on the pencil on the dataset created. 
+
+**Output:**
+
+Create the galaxy dataset corresponding to your file on servers.
+
+.. class:: infomark
+
+**Feedback**: alban.lermine@curie.fr
+  </help>
+</tool>