Updates to modules -- should remove defaults #36
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: nf-core CI | |
# This workflow runs the pipeline with the minimal test dataset to check that it completes without any syntax errors | |
on: | |
push: | |
branches: | |
- dev | |
pull_request: | |
release: | |
types: [published] | |
env: | |
NXF_ANSI_LOG: false | |
NXF_SINGULARITY_CACHEDIR: ${{ github.workspace }}/.singularity | |
NXF_SINGULARITY_LIBRARYDIR: ${{ github.workspace }}/.singularity | |
concurrency: | |
group: "${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}" | |
cancel-in-progress: true | |
jobs: | |
test: | |
name: Run pipeline with test data | |
# Only run on push if this is the nf-core dev branch (merged PRs) | |
if: "${{ github.event_name != 'push' || (github.event_name == 'push' && github.repository == 'sanger-tol/ear') }}" | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
NXF_VER: | |
- "24.04.0" | |
- "latest-everything" | |
steps: | |
- name: Get branch names | |
# Pulls the names of current branches in repo | |
# steps.branch-names.outputs.current_branch is used later and returns the name of the branch the PR is made FROM not to | |
id: branch-names | |
uses: tj-actions/branch-names@v8 | |
- name: Setup apptainer | |
uses: eWaterCycle/setup-apptainer@main | |
- name: Set up Singularity | |
run: | | |
mkdir -p $NXF_SINGULARITY_CACHEDIR | |
mkdir -p $NXF_SINGULARITY_LIBRARYDIR | |
- name: Install Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: "3.10" | |
- name: Install nf-core | |
run: | | |
pip install nf-core | |
- name: Check out pipeline code | |
uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4 | |
- name: Install Nextflow | |
uses: nf-core/setup-nextflow@v2 | |
with: | |
version: "${{ matrix.NXF_VER }}" | |
# This will only download the main pipeline containers, subpipelines need their own nf-download | |
- name: NF-Core Download - download singularity containers | |
run: | | |
nf-core download sanger-tol/ear --revision ${{ steps.branch-names.outputs.current_branch }} --compress none -d --force --outdir sanger-ear --container-cache-utilisation amend --container-system singularity | |
- name: Download Tiny test data | |
# Download A fungal test data set that is full enough to show some real output. | |
# Needs a kmer db for merqury | |
run: | | |
curl https://tolit.cog.sanger.ac.uk/test-data/resources/treeval/TreeValTinyData.tar.gz | tar xzf - | |
cp TreeValTinyData/assembly/draft/grTriPseu1.fa TreeValTinyData/assembly/draft/grTriPseu1-hap.fa | |
cp TreeValTinyData/assembly/draft/grTriPseu1.fa TreeValTinyData/assembly/draft/grTriPseu1-all_hap.fa | |
# - name: Disk space cleanup | |
# uses: jlumbroso/free-disk-space@54081f138730dfa15788a46383842cd2f914a1be # v1.3.1 | |
- name: Run pipeline with test data | |
# TODO nf-core: You can customise CI pipeline run tests as required | |
# For example: adding multiple test runs with different parameters | |
# Remember that you can parallelise this by using strategy.matrix | |
# Skip BTK and CPRETEXT as they are already tested on their repos. | |
run: | | |
nextflow run ${GITHUB_WORKSPACE} -profile test,docker --outdir ./results --steps btk,cpretext,merquryfk |