-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathTOP_old.sh
executable file
·48 lines (38 loc) · 1.75 KB
/
TOP_old.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#!/bin/bash
source activate top_nf
if [[ ${1} == "--update" ]]
then
echo "Updating The One Pipeline"
wget -O ${CONDA_PREFIX}/bin/TOP.nf https://github.com/garcia-nacho/TOP/raw/master/TOP.nf
wget -O ${CONDA_PREFIX}/bin/nextflow.config https://github.com/garcia-nacho/TOP/raw/master/nextflow.config
wget -O ${CONDA_PREFIX}/top_template.html https://github.com/garcia-nacho/TOP/raw/master/top_template.html
wget -O ${CONDA_PREFIX}/bin/TOP.sh https://github.com/garcia-nacho/TOP/raw/master/TOP.sh
docker pull ghcr.io/garcia-nacho/top_spades
docker pull ghcr.io/garcia-nacho/top_abricate
docker pull ghcr.io/garcia-nacho/top_emmtyper
docker pull ghcr.io/garcia-nacho/top_hicap
docker pull ghcr.io/garcia-nacho/top_seroba
docker pull ghcr.io/garcia-nacho/top_virfinder
#docker pull ghcr.io/garcia-nacho/top_prokka
docker pull ghcr.io/garcia-nacho/top_ngstar
docker pull ghcr.io/garcia-nacho/top_tbpipeline
docker pull ghcr.io/garcia-nacho/top_seqsero
docker pull ghcr.io/garcia-nacho/top_ngmaster
docker pull ghcr.io/garcia-nacho/top_ecoli
docker pull ghcr.io/garcia-nacho/top_meningotype
docker pull ghcr.io/garcia-nacho/top_tartrate
else
echo "Running The One Pipeline"
nextflow ${CONDA_PREFIX}/bin/TOP.nf --readsfolder "${1}" --krakenDB "${KRAKENDB}" --TBDB "${TBDB}" --tempfolder "${TEMPDB}" --spadescores ${SPADESCORES} --threads ${TOPCORES} -resume -with-timeline -with-report
#Delete working directory if there is no error
if test -f "${1}/TOPresults/Summaries_"*".xlsx"
then
echo "Cleaning up..."
rm -rf work
fi
if test -f "${1}/TOPresults/TB_Pipeline/Non_MTBC_samples_in_the_run"
then
rm -rf ${1}/TOPresults/TB_Pipeline/
fi
fi
conda deactivate