LinuxCommandLibrary

snakefmt

Format Snakemake files.

TLDR

Format a specific Snakefile

$ snakefmt [path/to/snakefile]
copy


Format all Snakefiles recursively in a specific directory
$ snakefmt [path/to/directory]
copy


Format a file using a specific configuration file
$ snakefmt --config [path/to/config.toml] [path/to/snakefile]
copy


Format a file using a specific maximum line length
$ snakefmt --line-length [100] [path/to/snakefile]
copy


Display the changes that would be performed without performing them (dry-run)
$ snakefmt --diff [path/to/snakefile]
copy

Copied to clipboard