Update a module
You can update modules installed from a remote repository in your pipeline using nf-core modules update
.
You can pass the module name as an optional argument to nf-core modules update
instead of using the cli prompt, eg: nf-core modules update fastqc
. You can specify a pipeline directory other than the current working directory by using the --dir <pipeline dir>
.
There are five additional flags that you can use with this command:
--force
: Reinstall module even if it appears to be up to date--prompt
: Select the module version using a cli prompt.--sha <commit_sha>
: Install the module at a specific commit from thenf-core/modules
repository.--preview/--no-preview
: Show the diff between the installed files and the new version before installing.--save-diff <filename>
: Save diffs to a file instead of updating in place. The diffs can then be applied withgit apply <filename>
.--all
: Use this flag to run the command on all modules in the pipeline.
If you don’t want to update certain modules or want to update them to specific versions, you can make use of the .nf-core.yml
configuration file. For example, you can prevent the star/align
module installed from nf-core/modules
from being updated by adding the following to the .nf-core.yml
file:
If you want this module to be updated only to a specific version (or downgraded), you could instead specifiy the version:
This also works at the repository level. For example, if you want to exclude all modules installed from nf-core/modules
from being updated you could add:
or if you want all modules in nf-core/modules
at a specific version:
Note that the module versions specified in the .nf-core.yml
file has higher precedence than versions specified with the command line flags, thus aiding you in writing reproducible pipelines.