comparison get_test_data.sh @ 0:6e13890afaef draft default tip

"planemo upload for repository https://github.com/ebi-gene-expression-group/container-galaxy-sc-tertiary/tree/develop/tools/qc/fastq_pair commit e8517297f4bf2ab5afc544e6af7bb4c5f152dd3e"
author ebi-gxa
date Thu, 17 Mar 2022 01:46:15 +0000
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:6e13890afaef
1 #!/usr/bin/env bash
2
3 BASE_LINK="https://raw.githubusercontent.com/linsalrob/fastq-pair/master/test"
4
5 LEFT_FILE="left.fastq"
6 RIGHT_FILE="right.fastq"
7 LEFTGZ_FILE="left.fastq.gz"
8 RIGHTGZ_FILE="right.fastq.gz"
9
10 LEFT_LINK=$BASE_LINK"/"$LEFT_FILE
11 RIGHT_LINK=$BASE_LINK"/"$RIGHT_FILE
12 LEFTGZ_LINK=$BASE_LINK"/"$LEFTGZ_FILE
13 RIGHTGZ_LINK=$BASE_LINK"/"$RIGHTGZ_FILE
14
15 function get_data {
16 local link=$1
17 local fname=$2
18
19 if [ ! -f $fname ]; then
20 echo "$fname not available locally, downloading.."
21 wget -O $fname --retry-connrefused --waitretry=1 --read-timeout=20 --timeout=15 -t 3 $link
22 fi
23 }
24
25 # Get test data
26 pushd test-data
27
28 get_data $LEFT_LINK $LEFT_FILE
29 get_data $RIGHT_LINK $RIGHT_FILE
30 get_data $LEFTGZ_LINK $LEFTGZ_FILE
31 get_data $RIGHTGZ_LINK $RIGHTGZ_FILE