snakedeploy icon indicating copy to clipboard operation
snakedeploy copied to clipboard

Add subcommand for conda env version and wrapper bumping

Open johanneskoester opened this issue 4 years ago • 0 comments

We should add a subcommand

snakedeploy bump-conda-versions [ENVYAML, [ENVYAML, ...]]

which does the following. Given paths to environment YAML files, it would

  • Extract package names and channels from the env.
  • Run mamba create --dry-run --json -c .
  • Extract the versions from the packages in the json that also occur in the original env.
  • Rewrite the env with minor version pinnings derived from the extracted versions.

This can (a) be used to update all environments (except wrappers) in a workflow to the latest minor release, and (b) be used to update all wrapper envs in snakemake/snakemake-wrappers. The latter can be used in a weekly CI job which would automatically create a PR in case of new changes. The same github action can also be offered for workflows actually.

In addition, we should have another subcommand

snakedeploy bump-wrappers [SNAKEFILE, [SNAKEFILE, ...]]

which would bump all wrapper directives in a given Snakefile to the latest stable wrapper release. Again, this can come in combination with a github action that automatically creates a PR.

johanneskoester avatar Jun 28 '21 07:06 johanneskoester