diff --git a/CLIP-seq b/CLIP-seq new file mode 120000 index 0000000000000000000000000000000000000000..a6346133c792207afa6cb4ca97283592823c7da5 --- /dev/null +++ b/CLIP-seq @@ -0,0 +1 @@ +CLIP \ No newline at end of file diff --git a/CLIP/iCLIP-seq.snakefile b/CLIP/iCLIP-seq.snakefile new file mode 120000 index 0000000000000000000000000000000000000000..f746f80e4d64050cb95c2e0c121a12e1ab52367b --- /dev/null +++ b/CLIP/iCLIP-seq.snakefile @@ -0,0 +1 @@ +iCLIP.snakefile \ No newline at end of file diff --git a/GRO-seq b/GRO-seq new file mode 120000 index 0000000000000000000000000000000000000000..7deb020b8bdad27fc39f1140635c6520d66c87b4 --- /dev/null +++ b/GRO-seq @@ -0,0 +1 @@ +PRO-seq \ No newline at end of file diff --git a/PRO-seq/GRO-seq.snakefile b/PRO-seq/GRO-seq.snakefile new file mode 120000 index 0000000000000000000000000000000000000000..896853bdf9dc6942e41b6d8aaedc55ab1d63b1eb --- /dev/null +++ b/PRO-seq/GRO-seq.snakefile @@ -0,0 +1 @@ +PRO-seq.snakefile \ No newline at end of file diff --git a/RNA-seq b/RNA-seq new file mode 120000 index 0000000000000000000000000000000000000000..c345b90088cd32ab599cd7d2525c897e1844119f --- /dev/null +++ b/RNA-seq @@ -0,0 +1 @@ +RNA_Seq_Cecere \ No newline at end of file diff --git a/iCLIP b/iCLIP new file mode 120000 index 0000000000000000000000000000000000000000..a6346133c792207afa6cb4ca97283592823c7da5 --- /dev/null +++ b/iCLIP @@ -0,0 +1 @@ +CLIP \ No newline at end of file diff --git a/iCLIP-seq b/iCLIP-seq new file mode 120000 index 0000000000000000000000000000000000000000..ddfad45ba723ed0e4fda501c22380f071063d524 --- /dev/null +++ b/iCLIP-seq @@ -0,0 +1 @@ +iCLIP \ No newline at end of file diff --git a/run_GRO-seq_pipeline b/run_GRO-seq_pipeline new file mode 120000 index 0000000000000000000000000000000000000000..f2500be890328630b8c7beb464f832ac55c298a9 --- /dev/null +++ b/run_GRO-seq_pipeline @@ -0,0 +1 @@ +run_pipeline.sh \ No newline at end of file diff --git a/run_PRO-seq_pipeline b/run_PRO-seq_pipeline new file mode 120000 index 0000000000000000000000000000000000000000..f2500be890328630b8c7beb464f832ac55c298a9 --- /dev/null +++ b/run_PRO-seq_pipeline @@ -0,0 +1 @@ +run_pipeline.sh \ No newline at end of file diff --git a/run_RNA-seq_pipeline b/run_RNA-seq_pipeline new file mode 120000 index 0000000000000000000000000000000000000000..f2500be890328630b8c7beb464f832ac55c298a9 --- /dev/null +++ b/run_RNA-seq_pipeline @@ -0,0 +1 @@ +run_pipeline.sh \ No newline at end of file diff --git a/run_Ribo-seq_pipeline b/run_Ribo-seq_pipeline new file mode 120000 index 0000000000000000000000000000000000000000..f2500be890328630b8c7beb464f832ac55c298a9 --- /dev/null +++ b/run_Ribo-seq_pipeline @@ -0,0 +1 @@ +run_pipeline.sh \ No newline at end of file diff --git a/run_iCLIP-seq_pipeline b/run_iCLIP-seq_pipeline new file mode 120000 index 0000000000000000000000000000000000000000..f2500be890328630b8c7beb464f832ac55c298a9 --- /dev/null +++ b/run_iCLIP-seq_pipeline @@ -0,0 +1 @@ +run_pipeline.sh \ No newline at end of file diff --git a/run_iCLIP_pipeline b/run_iCLIP_pipeline new file mode 120000 index 0000000000000000000000000000000000000000..f2500be890328630b8c7beb464f832ac55c298a9 --- /dev/null +++ b/run_iCLIP_pipeline @@ -0,0 +1 @@ +run_pipeline.sh \ No newline at end of file diff --git a/run_pipeline.sh b/run_pipeline.sh new file mode 100755 index 0000000000000000000000000000000000000000..ad6a528bddbe1902b1f6d55fce5c46b625e6e272 --- /dev/null +++ b/run_pipeline.sh @@ -0,0 +1,74 @@ +#!/bin/bash +# Usage: run_pipeline.sh [<snakefile>] <configuration_file> [extra arguments for snakemake] +# If no snakefile is provided, the script should be called from one of its aliases. +# Each alias will run a specific pipeline, depending on its name. + +# http://linuxcommand.org/wss0150.php +PROGNAME=$(basename "${0}") + +function error_exit +{ +# ---------------------------------------------------------------- +# Function for exit due to fatal program error +# Accepts 1 argument: +# string containing descriptive error message +# ---------------------------------------------------------------- + echo "${PROGNAME}: ${1:-"Unknown Error"}" 1>&2 + exit 1 +} + +# https://stackoverflow.com/a/1638397/1878788 +# Absolute path to this script +SCRIPT=$(readlink -f "${0}") +# Absolute path this script is in +BASEDIR=$(dirname "${SCRIPT}") + +# This script can be called from various symbolic links. +# The name of the link determines which snakefile to use. +# PRO-seq and GRO-seq are actually the same pipeline +# similarly for sRNA-seq and small_RNA-seq +# similarly for iCLIP-seq and iCLIP +case "${PROGNAME}" in + "run_RNA-seq_pipeline") + snakefile="${BASEDIR}/RNA-seq/RNA-seq.snakefile" + ;; + "run_GRO-seq_pipeline") + snakefile="${BASEDIR}/PRO-seq/GRO-seq.snakefile" + ;; + "run_PRO-seq_pipeline") + snakefile="${BASEDIR}/PRO-seq/PRO-seq.snakefile" + ;; + "run_small_RNA-seq_pipeline") + snakefile="${BASEDIR}/small_RNA-seq/small_RNA-seq.snakefile" + ;; + "run_sRNA-seq_pipeline") + snakefile="${BASEDIR}/sRNA-seq/sRNA-seq.snakefile" + ;; + "run_iCLIP-seq_pipeline") + snakefile="${BASEDIR}/iCLIP-seq/iCLIP-seq.snakefile" + ;; + "run_iCLIP_pipeline") + snakefile="${BASEDIR}/iCLIP/iCLIP.snakefile" + ;; + "run_Ribo-seq_pipeline") + snakefile="${BASEDIR}/Ribo-seq/Ribo-seq.snakefile" + ;; + *) + snakefile="${1}" + shift + ;; +esac + +configfile="${1}" +shift + +if [ -e ${configfile} ] +then + cmd="snakemake -s ${snakefile} --configfile ${configfile} $@" +else + error_exit "Pipeline configuration file ${configfile} not found." +fi +echo ${cmd} +eval ${cmd} || error_exit "${cmd} failed" + +exit 0 diff --git a/run_sRNA-seq_pipeline b/run_sRNA-seq_pipeline new file mode 120000 index 0000000000000000000000000000000000000000..f2500be890328630b8c7beb464f832ac55c298a9 --- /dev/null +++ b/run_sRNA-seq_pipeline @@ -0,0 +1 @@ +run_pipeline.sh \ No newline at end of file diff --git a/run_small_RNA-seq_pipeline b/run_small_RNA-seq_pipeline new file mode 120000 index 0000000000000000000000000000000000000000..f2500be890328630b8c7beb464f832ac55c298a9 --- /dev/null +++ b/run_small_RNA-seq_pipeline @@ -0,0 +1 @@ +run_pipeline.sh \ No newline at end of file diff --git a/small_RNA-seq/sRNA-seq.snakefile b/small_RNA-seq/sRNA-seq.snakefile new file mode 120000 index 0000000000000000000000000000000000000000..c6ff303d5a4ff9581b51b98c8367a2ac4d34c522 --- /dev/null +++ b/small_RNA-seq/sRNA-seq.snakefile @@ -0,0 +1 @@ +small_RNA-seq.snakefile \ No newline at end of file