Skip to content

Commit 9976402

Browse files
author
Szilveszter Juhos
authored
Merge pull request nf-core#577 from MaxUlysse/NewTestAndRefs
Use new repo for test and reference
2 parents 5b3f27d + 0a446ca commit 9976402

65 files changed

Lines changed: 39 additions & 134 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.gitignore

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,11 @@ Annotation/
22
Preprocessing/
33
References/
44
Reports/
5+
Sarek-data/
56
VariantCalling/
67
work/
78
.*swp
9+
.DS_Store
810
.nextflow*
911
*.img
1012
*.tar.gz
11-
report.html*
12-
timeline.html*
13-
trace.txt*
14-
.DS_Store

buildReferences.nf

Lines changed: 2 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -56,14 +56,7 @@ if (params.help) exit 0, helpMessage()
5656
if (!SarekUtils.isAllowedParams(params)) exit 1, "params unknown, see --help for more information"
5757
if (!checkUppmaxProject()) exit 1, "No UPPMAX project ID found! Use --project <UPPMAX Project ID>"
5858

59-
if (!params.download && params.refDir == "" ) exit 1, "No --refDir specified"
60-
if (params.download && params.refDir != "" ) exit 1, "No need to specify --refDir"
61-
62-
ch_referencesFiles = defReferencesFiles(params.genome)
63-
64-
if (params.download && params.genome != "smallGRCh37") exit 1, "Not possible to download ${params.genome} references files"
65-
66-
if (!params.download) ch_referencesFiles.each{checkFile(params.refDir + "/" + it)}
59+
ch_referencesFiles = Channel.fromPath("${params.refDir}/*")
6760

6861
/*
6962
================================================================================
@@ -73,37 +66,10 @@ if (!params.download) ch_referencesFiles.each{checkFile(params.refDir + "/" + it
7366

7467
startMessage()
7568

76-
process ProcessReference {
77-
tag params.download ? {"Download: " + f_reference} : {"Link: " + f_reference}
78-
79-
input:
80-
val(f_reference) from ch_referencesFiles
81-
82-
output:
83-
file(f_reference) into ch_processedFiles
84-
85-
script:
86-
87-
if (params.download)
88-
"""
89-
wget https://github.com/szilvajuhos/smallRef/raw/master/${f_reference}
90-
"""
91-
92-
else
93-
"""
94-
ln -s ${params.refDir}/${f_reference} .
95-
"""
96-
}
97-
98-
99-
if (params.verbose) ch_processedFiles = ch_processedFiles.view {
100-
"Files preprocessed : ${it.fileName}"
101-
}
102-
10369
ch_compressedfiles = Channel.create()
10470
ch_notCompressedfiles = Channel.create()
10571

106-
ch_processedFiles
72+
ch_referencesFiles
10773
.choice(ch_compressedfiles, ch_notCompressedfiles) {it =~ ".(gz|tar.bz2)" ? 0 : 1}
10874

10975
process DecompressFile {
@@ -294,9 +260,6 @@ def helpMessage() {
294260
this.sarekMessage()
295261
log.info " Usage:"
296262
log.info " nextflow run buildReferences.nf --refDir <pathToRefDir> --genome <genome>"
297-
log.info " nextflow run buildReferences.nf --download --genome smallGRCh37"
298-
log.info " --download"
299-
log.info " Download reference files. (only with --genome smallGRCh37)"
300263
log.info " --refDir <Directoy>"
301264
log.info " Specify a directory containing reference files."
302265
log.info " --outDir <Directoy>"
-4.75 KB
Binary file not shown.
-4.67 KB
Binary file not shown.
-4.76 KB
Binary file not shown.
-4.69 KB
Binary file not shown.
-5.13 KB
Binary file not shown.
-5.08 KB
Binary file not shown.
-2.77 KB
Binary file not shown.
-2.75 KB
Binary file not shown.

0 commit comments

Comments
 (0)