learners
Setup
Snakemake can be installed in several ways. In this lesson, we use Pixi because it is fast and keeps the environment setup simple.
Installing Pixi
If CVMFS is available, we recommend to source the setup.sh as
described below.
source /cvmfs/cms-griddata.cern.ch/cat/sw/pixi/latest/setup.shCheck that pixi is available:
pixi versionThe first episodes only need Snakemake itself. The later episode on containers also needs Apptainer, which is usually easiest on a Linux system where Apptainer is already available, such as LxPlus or a Tier-3 cluster.
If you are working locally on macOS or Windows, you can still follow the early episodes, but you may want to switch to such a system for the container material.
Installing Snakemake
We will use a dedicated directory for this tutorial:
mkdir snakemake-tutorial
cd snakemake-tutorial
pixi init
pixi workspace channel add conda-forge
pixi workspace channel add bioconda
pixi add snakemakeTo activate the environment, run:
pixi shellSnakemake should then be available:
snakemake --helpYou can also run Snakemake without activating the shell
(type exit to get out of it) directly through pixi:
pixi run snakemake --helpNext step
Now you’re ready to start using Snakemake.