Skip to content
You're viewing an older version of this GitHub Action. Do you want to see the latest version instead?
shuffle

GitHub Action

Setup Nextflow

v1.0.0

Setup Nextflow

shuffle

Setup Nextflow

Install Nextflow and add it to the PATH

Installation

Copy and paste the following snippet into your .yml file.

              

- name: Setup Nextflow

uses: nf-core/[email protected]

Learn more about this action in nf-core/setup-nextflow

Choose a version

Setup Nextflow for GitHub Actions

Testing MIT License GitHub tag (latest by date) Get from GitHub Actions

An action to install Nextflow into a GitHub Actions workflow and make it available for subsequent steps.

Quick start

name: Example workflow
on: push
jobs:
  example:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - uses: actions/setup-java@v3
        with:
          distribution: "temurin"
          java-version: "11"
      - uses: MillironX/setup-nextflow@v1
        with:
          version: "21.10"
          all: false
          token: ${{ secrets.GITHUB_TOKEN }}
      - run: nextflow help

Inputs

version

default: latest

A version string to specify the version of Nextflow to install. This version number will try to resolve using npm's semantic versioning, so

  • version: 21
  • version: 21.10
  • version: 21.10.6

will all download Nextflow version 21.10.6 as of 13 June 2022. Since Nextflow does not use true semantic versioning, you should always specify at least the minor version (e.g. version: 21.10).

Edge releases are resolved as pre-release, see https://github.com/npm/node-semver#prerelease-tags for more details. In short, in nearly all cases, passing an -edge release to this action will need to specify the exact edge release targeted.

There are three (technically four) aliases to assist in choosing up-to-date Nextflow versions.

  • version: latest-stable (alias version: latest)

    This will download the latest stable release of Nextflow.

  • version: latest-edge

    This will download the latest edge release of Nextflow. Note that edge releases may be older than the latest stable release. See nextflow-io/nextflow#2467

  • version: latest-everything

    This will download the latest release of Nextflow, regardless of stable/edge status.

all

default: false

A boolean deciding whether to download the "all versions" distribution of Nextflow. May be useful for running tests against multiple versions downstream.

token

default: ${{ secrets.GITHUB_TOKEN }}

This action locates the releases based upon the GitHub API, and requires an access token. The default token provided with all GitHub actions should be sufficient for all use cases.

Outputs

There are no outputs from this action.