Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move conda environment to yml #4079

Merged
merged 6 commits into from
Oct 24, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
24 changes: 24 additions & 0 deletions .github/convert_conda_line_to_env.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#!/usr/bin/env bash

# Find all main.nf files in modules
NF_FILES=$(fd "^main.nf$" modules/)

template=".github/env-template.yml"

for file in $NF_FILES; do
# Get the conda line
conda_line=$(rg "^ conda" "$file")
# Pull out the conda packages
conda_packages=$(echo "$conda_line" | sed 's/^.*"\(.*\)".*$/\1/g')
# Write the template to the environment.yml
cat $template > $(dirname "$file")/environment.yml

env_yaml=$(dirname "$file")/environment.yml
# Put the dependencies in a environment.yaml using yq
for package in $conda_packages; do
yq -i '.dependencies += ["'"$package"'"]' $env_yaml
done

# Change the conda line to point to the new environment.yml
sed -i "s|^ conda.*| conda '$env_yaml'|g" "$file"
done
4 changes: 4 additions & 0 deletions .github/env-template.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
channels:
- conda-forge
- bioconda
- defaults
6 changes: 6 additions & 0 deletions modules/nf-core/abacas/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::abacas=1.3.1
2 changes: 1 addition & 1 deletion modules/nf-core/abacas/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process ABACAS {
tag "$meta.id"
label 'process_medium'

conda "bioconda::abacas=1.3.1"
conda 'modules/nf-core/abacas/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/abacas:1.3.1--pl526_0' :
'biocontainers/abacas:1.3.1--pl526_0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/abricate/run/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::abricate=1.0.1
2 changes: 1 addition & 1 deletion modules/nf-core/abricate/run/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process ABRICATE_RUN {
tag "$meta.id"
label 'process_medium'

conda "bioconda::abricate=1.0.1"
conda 'modules/nf-core/abricate/run/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/abricate%3A1.0.1--ha8f3691_1':
'biocontainers/abricate:1.0.1--ha8f3691_1' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/abricate/summary/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::abricate=1.0.1
2 changes: 1 addition & 1 deletion modules/nf-core/abricate/summary/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process ABRICATE_SUMMARY {
tag "$meta.id"
label 'process_single'

conda "bioconda::abricate=1.0.1"
conda 'modules/nf-core/abricate/summary/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/abricate%3A1.0.1--ha8f3691_1':
'biocontainers/abricate:1.0.1--ha8f3691_1' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/abritamr/run/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::abritamr=1.0.14
2 changes: 1 addition & 1 deletion modules/nf-core/abritamr/run/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process ABRITAMR_RUN {
tag "$meta.id"
label 'process_low'

conda "bioconda::abritamr=1.0.14"
conda 'modules/nf-core/abritamr/run/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/abritamr:1.0.14--pyhdfd78af_0':
'biocontainers/abritamr:1.0.14--pyhdfd78af_0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/adapterremoval/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::adapterremoval=2.3.2
2 changes: 1 addition & 1 deletion modules/nf-core/adapterremoval/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process ADAPTERREMOVAL {
tag "$meta.id"
label 'process_medium'

conda "bioconda::adapterremoval=2.3.2"
conda 'modules/nf-core/adapterremoval/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/adapterremoval:2.3.2--hb7ba0dd_0' :
'biocontainers/adapterremoval:2.3.2--hb7ba0dd_0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/adapterremovalfixprefix/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::adapterremovalfixprefix=0.0.5
2 changes: 1 addition & 1 deletion modules/nf-core/adapterremovalfixprefix/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ process ADAPTERREMOVALFIXPREFIX {
label 'process_single'

// WARN: Version information not provided by tool on CLI. Please update version string below when bumping container versions.
conda "bioconda::adapterremovalfixprefix=0.0.5"
conda 'modules/nf-core/adapterremovalfixprefix/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/adapterremovalfixprefix:0.0.5--hdfd78af_2':
'biocontainers/adapterremovalfixprefix:0.0.5--hdfd78af_2' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/admixture/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::admixture=1.3.0
2 changes: 1 addition & 1 deletion modules/nf-core/admixture/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ process ADMIXTURE {
tag "$meta.id"
label 'process_medium'

conda "bioconda::admixture=1.3.0"
conda 'modules/nf-core/admixture/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/admixture:1.3.0--0':
'biocontainers/admixture:1.3.0--0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/affy/justrma/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::bioconductor-affy=1.78.0
2 changes: 1 addition & 1 deletion modules/nf-core/affy/justrma/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process AFFY_JUSTRMA {
tag "$meta.id"
label 'process_single'

conda "bioconda::bioconductor-affy=1.78.0"
conda 'modules/nf-core/affy/justrma/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/bioconductor-affy:1.78.0--r43ha9d7317_1':
'biocontainers/bioconductor-affy:1.78.0--r43ha9d7317_1' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/agat/convertspgff2gtf/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::agat=1.0.0
2 changes: 1 addition & 1 deletion modules/nf-core/agat/convertspgff2gtf/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process AGAT_CONVERTSPGFF2GTF {
tag "$meta.id"
label 'process_single'

conda "bioconda::agat=1.0.0"
conda 'modules/nf-core/agat/convertspgff2gtf/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/agat:1.0.0--pl5321hdfd78af_0' :
'biocontainers/agat:1.0.0--pl5321hdfd78af_0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/agat/convertspgxf2gxf/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::agat=1.0.0
2 changes: 1 addition & 1 deletion modules/nf-core/agat/convertspgxf2gxf/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process AGAT_CONVERTSPGXF2GXF {
tag "$meta.id"
label 'process_single'

conda "bioconda::agat=1.0.0"
conda 'modules/nf-core/agat/convertspgxf2gxf/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/agat:1.0.0--pl5321hdfd78af_0' :
'biocontainers/agat:1.0.0--pl5321hdfd78af_0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/agat/spstatistics/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::agat=1.0.0
2 changes: 1 addition & 1 deletion modules/nf-core/agat/spstatistics/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process AGAT_SPSTATISTICS {
tag "$meta.id"
label 'process_low'

conda "bioconda::agat=1.0.0"
conda 'modules/nf-core/agat/spstatistics/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/agat:1.0.0--pl5321hdfd78af_0' :
'biocontainers/agat:1.0.0--pl5321hdfd78af_0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/agat/sqstatbasic/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::agat=1.0.0
2 changes: 1 addition & 1 deletion modules/nf-core/agat/sqstatbasic/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process AGAT_SQSTATBASIC {
tag "$meta.id"
label 'process_low'

conda "bioconda::agat=1.0.0"
conda 'modules/nf-core/agat/sqstatbasic/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/agat:1.0.0--pl5321hdfd78af_0' :
'biocontainers/agat:1.0.0--pl5321hdfd78af_0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/agrvate/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::agrvate=1.0.2
2 changes: 1 addition & 1 deletion modules/nf-core/agrvate/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process AGRVATE {
tag "$meta.id"
label 'process_low'

conda "bioconda::agrvate=1.0.2"
conda 'modules/nf-core/agrvate/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/agrvate:1.0.2--hdfd78af_0' :
'biocontainers/agrvate:1.0.2--hdfd78af_0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/allelecounter/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::cancerit-allelecount=4.3.0
2 changes: 1 addition & 1 deletion modules/nf-core/allelecounter/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process ALLELECOUNTER {
tag "$meta.id"
label 'process_low'

conda "bioconda::cancerit-allelecount=4.3.0"
conda 'modules/nf-core/allelecounter/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/cancerit-allelecount:4.3.0--h41abebc_0' :
'biocontainers/cancerit-allelecount:4.3.0--h41abebc_0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/ampcombi/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::ampcombi=0.1.7
2 changes: 1 addition & 1 deletion modules/nf-core/ampcombi/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process AMPCOMBI {
tag "$meta.id"
label 'process_medium'

conda "bioconda::ampcombi=0.1.7"
conda 'modules/nf-core/ampcombi/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/ampcombi:0.1.7--pyhdfd78af_0':
'biocontainers/ampcombi:0.1.7--pyhdfd78af_0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/ampir/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- conda-forge::r-ampir=1.1.0
2 changes: 1 addition & 1 deletion modules/nf-core/ampir/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process AMPIR {
tag "$meta.id"
label 'process_single'

conda "conda-forge::r-ampir=1.1.0"
conda 'modules/nf-core/ampir/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/r-ampir:1.1.0':
'biocontainers/r-ampir:1.1.0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/amplify/predict/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::amplify=1.1.0
2 changes: 1 addition & 1 deletion modules/nf-core/amplify/predict/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ process AMPLIFY_PREDICT {
label 'process_single'

// WARN: Version information not provided by tool on CLI. Please update version string below when bumping container versions.
conda "bioconda::amplify=1.1.0"
conda 'modules/nf-core/amplify/predict/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/amplify:1.1.0--hdfd78af_0':
'biocontainers/amplify:1.1.0--hdfd78af_0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/amps/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::hops=0.35
2 changes: 1 addition & 1 deletion modules/nf-core/amps/main.nf
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
process AMPS {
label 'process_low'

conda "bioconda::hops=0.35"
conda 'modules/nf-core/amps/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/hops:0.35--hdfd78af_1' :
'biocontainers/hops:0.35--hdfd78af_1' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/amrfinderplus/run/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::ncbi-amrfinderplus=3.11.18
2 changes: 1 addition & 1 deletion modules/nf-core/amrfinderplus/run/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process AMRFINDERPLUS_RUN {
tag "$meta.id"
label 'process_medium'

conda "bioconda::ncbi-amrfinderplus=3.11.18"
conda 'modules/nf-core/amrfinderplus/run/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/ncbi-amrfinderplus:3.11.18--h283d18e_0':
'biocontainers/ncbi-amrfinderplus:3.11.18--h283d18e_0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/amrfinderplus/update/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::ncbi-amrfinderplus=3.11.18
2 changes: 1 addition & 1 deletion modules/nf-core/amrfinderplus/update/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process AMRFINDERPLUS_UPDATE {
tag "update"
label 'process_single'

conda "bioconda::ncbi-amrfinderplus=3.11.18"
conda 'modules/nf-core/amrfinderplus/update/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/ncbi-amrfinderplus:3.11.18--h283d18e_0':
'biocontainers/ncbi-amrfinderplus:3.11.18--h283d18e_0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/angsd/contamination/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::angsd=0.940
2 changes: 1 addition & 1 deletion modules/nf-core/angsd/contamination/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process ANGSD_CONTAMINATION {
tag "$meta.id"
label 'process_low'

conda "bioconda::angsd=0.940"
conda 'modules/nf-core/angsd/contamination/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/angsd:0.939--h468462d_0':
'biocontainers/angsd:0.939--h468462d_0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/angsd/docounts/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::angsd=0.939
2 changes: 1 addition & 1 deletion modules/nf-core/angsd/docounts/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process ANGSD_DOCOUNTS {
tag "$meta.id"
label 'process_low'

conda "bioconda::angsd=0.939"
conda 'modules/nf-core/angsd/docounts/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/angsd:0.939--h468462d_0':
'biocontainers/angsd:0.939--h468462d_0' }"
Expand Down
6 changes: 6 additions & 0 deletions modules/nf-core/annotsv/annotsv/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- bioconda::annotsv=3.3.6
2 changes: 1 addition & 1 deletion modules/nf-core/annotsv/annotsv/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ process ANNOTSV_ANNOTSV {
tag "$meta.id"
label 'process_low'

conda "bioconda::annotsv=3.3.6"
conda 'modules/nf-core/annotsv/annotsv/environment.yml'
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/annotsv:3.3.6--py311hdfd78af_0' :
'biocontainers/annotsv:3.3.6--py311hdfd78af_0' }"
Expand Down
Loading
Loading