Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
genotoul-bioinfo
metagWGS
Commits
ca387e0f
Commit
ca387e0f
authored
Dec 29, 2021
by
Jean Mainguy
Browse files
manage accession2taxid file gz or not
parent
ff63c2ec
Changes
1
Hide whitespace changes
Inline
Side-by-side
subworkflows/00_databases.nf
View file @
ca387e0f
...
...
@@ -64,8 +64,24 @@ workflow DATABASES {
ch_taxonomy
=
DOWNLOAD_TAXONOMY_DB
.
out
.
taxonomy
}
else
if
(
params
.
taxonomy_dir
)
{
ch_accession2taxid
=
Channel
.
fromPath
(
params
.
taxonomy_dir
+
'/prot.accession2taxid.FULL'
,
checkIfExists:
true
)
// Process accession2taxid file
accession2taxid_gz
=
params
.
taxonomy_dir
+
'/prot.accession2taxid.FULL.gz'
accession2taxid
=
file
(
params
.
taxonomy_dir
+
'/prot.accession2taxid.FULL'
)
if
(
file
(
accession2taxid_gz
).
isFile
())
{
ch_accession2taxid
=
Channel
.
fromPath
(
accession2taxid_gz
,
checkIfExists:
true
)
}
else
if
(
accession2taxid
.
isFile
())
{
ch_accession2taxid
=
Channel
.
fromPath
(
accession2taxid
,
checkIfExists:
true
)
}
else
{
exit
1
,
"$accession2taxid[.gz] is expected but does not exist in the given --taxonomy_dir $params.taxonomy_dir."
}
// Process taxdump dir
ch_taxdump
=
Channel
.
fromPath
(
params
.
taxonomy_dir
+
'/new_taxdump'
,
checkIfExists:
true
)
ch_taxonomy
=
ch_accession2taxid
.
combine
(
ch_taxdump
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment