This repository is depreciated and has now been archived. Instead of using the cookiecutter command line tool to make new pipelines, please use the nf-core/tools package instead.
The above package now has the command
nf-core create which basically does the same as described below (but with some added features). Please use that instead!
cookiecutter with this repository to create a new Nextflow pipeline built with the details that you add when prompted. This gives a quick route to a solid pipeline that uses lots of Nextflow best-practices and nice features.
Specifically, it comes with:
--genome [genome ID]
To use this template, first install cookiecutter:
pip install cookiecutter
Then run the wizard with this repository:
Create a new repository to hold your pipeline on GitHub. Match the variables that you entered whilst running the cookiecutter script (
github_repo). Don't initialise with a README or any files, leave it blank.
Back on your computer, change directory into your new pipeline folder and initialise a git repository:
Add your generated files, commit and push to GitHub:
git add . git commit -m "First commit, based on nf-core/cookiecutter template" git remote add origin [your github remote url] git push -u origin master
Using the examples of FastQC and MultiQC, add in the steps that you want in your pipeline.
Remember that you can add process-specific configuration (eg. memory requirements) in
Your Nextflow pipeline will work best when using Docker and Singularity to handle software requirements. The pipeline comes with a basic Docker template file (Dockerfile) which installs FastQC and MultiQC. Edit this to add in any additional software packages that you need.
Nextflow and this pipeline are set up to automatically pull the docker image when the pipeline runs. Set up a new docker image on dockerhub (https://hub.docker.com/) at the address that you entered in the setup (
Make sure that you create an Automated Build that is connected to your GitHub repository and set to automatically build an image when you commit to master. Add a second automated build under Build Settings so that an image is built when you create a new tag (stick with the default - every tag, same name as tag).
This cookiecutter comes with some basic documentation that's general to Nextflow, but you'll want to write some docs which are specific to your pipeline.
docs/output.md is converted to HTML by the pipeline and saved to the results directory, so you'll want to be especially sure that this contains useful information.
Edit the demo data URL in
tests/run_test.sh to point to a valid location and edit to run with required configuration.
Go to https://travis-ci.org/ and enable testing on your pipeline repository.
Once you're happy that your pipeline works, make a release on GitHub! This tags a stable version of your pipeline and associated docker image. People can then run your pipeline directly from GitHub with
-r [version] to get super reproducible results!
Remember to update the
version variable in your main script as you keep working after this.
If you can, please consider releasing your new pipeline as open source software! You can copy the
LICENCE.md file from this repository into your root directory to release under the MIT licence.
That's it! You've just made a super cool new analysis pipeline in very little time! Congratulations!