Skip to content

Commit 3ee1fe9

Browse files
authored
Merge pull request #315 from nf-core/dev
Dev -> Master for 2.5 release
2 parents 42e38bb + 74ee2b6 commit 3ee1fe9

File tree

99 files changed

+2206
-1635
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

99 files changed

+2206
-1635
lines changed

.editorconfig

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,9 @@ trim_trailing_whitespace = true
88
indent_size = 4
99
indent_style = space
1010

11-
[*.{yml,yaml}]
11+
[*.{md,yml,yaml,html,css,scss,js}]
1212
indent_size = 2
1313

14-
[*.json]
15-
insert_final_newline = unset
16-
1714
# These files are edited and tested upstream in nf-core/modules
1815
[/modules/nf-core/**]
1916
charset = unset

.github/CONTRIBUTING.md

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,7 @@ Contributions to the code are even more welcome ;)
1515

1616
If you'd like to write some code for nf-core/viralrecon, the standard workflow is as follows:
1717

18-
1. Check that there isn't already an issue about your idea in the [nf-core/viralrecon issues](https://github.com/nf-core/viralrecon/issues) to avoid duplicating work
19-
* If there isn't one already, please create one so that others know you're working on this
18+
1. Check that there isn't already an issue about your idea in the [nf-core/viralrecon issues](https://github.com/nf-core/viralrecon/issues) to avoid duplicating work. If there isn't one already, please create one so that others know you're working on this
2019
2. [Fork](https://help.github.com/en/github/getting-started-with-github/fork-a-repo) the [nf-core/viralrecon repository](https://github.com/nf-core/viralrecon) to your GitHub account
2120
3. Make the necessary changes / additions within your forked repository following [Pipeline conventions](#pipeline-contribution-conventions)
2221
4. Use `nf-core schema build` and add any new parameters to the pipeline JSON schema (requires [nf-core tools](https://github.com/nf-core/tools) >= 1.10).
@@ -49,9 +48,9 @@ These tests are run both with the latest available version of `Nextflow` and als
4948

5049
:warning: Only in the unlikely and regretful event of a release happening with a bug.
5150

52-
* On your own fork, make a new branch `patch` based on `upstream/master`.
53-
* Fix the bug, and bump version (X.Y.Z+1).
54-
* A PR should be made on `master` from patch to directly this particular bug.
51+
- On your own fork, make a new branch `patch` based on `upstream/master`.
52+
- Fix the bug, and bump version (X.Y.Z+1).
53+
- A PR should be made on `master` from patch to directly this particular bug.
5554

5655
## Getting help
5756

@@ -73,7 +72,7 @@ If you wish to contribute a new step, please use the following coding standards:
7372
6. Add sanity checks and validation for all relevant parameters.
7473
7. Perform local tests to validate that the new code works as expected.
7574
8. If applicable, add a new test command in `.github/workflow/ci.yml`.
76-
9. Update MultiQC config `assets/multiqc_config.yaml` so relevant suffixes, file name clean up and module plots are in the appropriate order. If applicable, add a [MultiQC](https://https://multiqc.info/) module.
75+
9. Update MultiQC config `assets/multiqc_config.yml` so relevant suffixes, file name clean up and module plots are in the appropriate order. If applicable, add a [MultiQC](https://https://multiqc.info/) module.
7776
10. Add a description of the output files and if relevant any appropriate images from the MultiQC report to `docs/output.md`.
7877

7978
### Default values
@@ -92,8 +91,8 @@ The process resources can be passed on to the tool dynamically within the proces
9291

9392
Please use the following naming schemes, to make it easy to understand what is going where.
9493

95-
* initial process channel: `ch_output_from_<process>`
96-
* intermediate and terminal channels: `ch_<previousprocess>_for_<nextprocess>`
94+
- initial process channel: `ch_output_from_<process>`
95+
- intermediate and terminal channels: `ch_<previousprocess>_for_<nextprocess>`
9796

9897
### Nextflow version bumping
9998

.github/ISSUE_TEMPLATE/bug_report.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ name: Bug report
22
description: Report something that is broken or incorrect
33
labels: bug
44
body:
5-
65
- type: markdown
76
attributes:
87
value: |

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,13 @@ Remember that PRs should be made against the dev branch, unless you're preparing
1010
1111
Learn more about contributing: [CONTRIBUTING.md](https://github.com/nf-core/viralrecon/tree/master/.github/CONTRIBUTING.md)
1212
-->
13-
<!-- markdownlint-disable ul-indent -->
1413

1514
## PR checklist
1615

1716
- [ ] This comment contains a description of changes (with reason).
1817
- [ ] If you've fixed a bug or added code that should be tested, add tests!
19-
- [ ] If you've added a new tool - have you followed the pipeline conventions in the [contribution docs](https://github.com/nf-core/viralrecon/tree/master/.github/CONTRIBUTING.md)
20-
- [ ] If necessary, also make a PR on the nf-core/viralrecon _branch_ on the [nf-core/test-datasets](https://github.com/nf-core/test-datasets) repository.
18+
- [ ] If you've added a new tool - have you followed the pipeline conventions in the [contribution docs](https://github.com/nf-core/viralrecon/tree/master/.github/CONTRIBUTING.md)
19+
- [ ] If necessary, also make a PR on the nf-core/viralrecon _branch_ on the [nf-core/test-datasets](https://github.com/nf-core/test-datasets) repository.
2120
- [ ] Make sure your code lints (`nf-core lint`).
2221
- [ ] Ensure the test suite passes (`nextflow run . -profile test,docker --outdir <OUTDIR>`).
2322
- [ ] Usage Documentation in `docs/usage.md` is updated.

.github/workflows/awsfulltest.yml

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,20 +18,14 @@ jobs:
1818
platform: ["illumina", "nanopore"]
1919
steps:
2020
- name: Launch workflow via tower
21-
uses: nf-core/tower-action@v2
22-
21+
uses: nf-core/tower-action@v3
2322
with:
2423
workspace_id: ${{ secrets.TOWER_WORKSPACE_ID }}
2524
access_token: ${{ secrets.TOWER_ACCESS_TOKEN }}
2625
compute_env: ${{ secrets.TOWER_COMPUTE_ENV }}
27-
pipeline: ${{ github.repository }}
28-
revision: ${{ github.sha }}
2926
workdir: s3://${{ secrets.AWS_S3_BUCKET }}/work/viralrecon/work-${{ github.sha }}
3027
parameters: |
3128
{
3229
"outdir": "s3://${{ secrets.AWS_S3_BUCKET }}/viralrecon/results-${{ github.sha }}/platform_${{ matrix.platform }}"
3330
}
3431
profiles: test_full_${{ matrix.platform }},aws_tower
35-
nextflow_config: |
36-
process.errorStrategy = 'retry'
37-
process.maxRetries = 3

.github/workflows/awstest.yml

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,21 +10,16 @@ jobs:
1010
if: github.repository == 'nf-core/viralrecon'
1111
runs-on: ubuntu-latest
1212
steps:
13+
# Launch workflow using Tower CLI tool action
1314
- name: Launch workflow via tower
14-
uses: nf-core/tower-action@v2
15-
15+
uses: nf-core/tower-action@v3
1616
with:
1717
workspace_id: ${{ secrets.TOWER_WORKSPACE_ID }}
1818
access_token: ${{ secrets.TOWER_ACCESS_TOKEN }}
1919
compute_env: ${{ secrets.TOWER_COMPUTE_ENV }}
20-
pipeline: ${{ github.repository }}
21-
revision: ${{ github.sha }}
2220
workdir: s3://${{ secrets.AWS_S3_BUCKET }}/work/viralrecon/work-${{ github.sha }}
2321
parameters: |
2422
{
2523
"outdir": "s3://${{ secrets.AWS_S3_BUCKET }}/viralrecon/results-test-${{ github.sha }}"
2624
}
2725
profiles: test,aws_tower
28-
nextflow_config: |
29-
process.errorStrategy = 'retry'
30-
process.maxRetries = 3

.github/workflows/branch.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ jobs:
1515
run: |
1616
{ [[ ${{github.event.pull_request.head.repo.full_name }} == nf-core/viralrecon ]] && [[ $GITHUB_HEAD_REF = "dev" ]]; } || [[ $GITHUB_HEAD_REF == "patch" ]]
1717
18-
1918
# If the above check failed, post a comment on the PR explaining the failure
2019
# NOTE - this doesn't currently work if the PR is coming from a fork, due to limitations in GitHub actions secrets
2120
- name: Post PR comment

.github/workflows/ci.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,20 +14,20 @@ env:
1414

1515
jobs:
1616
test:
17-
name: Run workflow tests
17+
name: Run pipeline with test data
1818
# Only run on push if this is the nf-core dev branch (merged PRs)
19-
if: ${{ github.event_name != 'push' || (github.event_name == 'push' && github.repository == 'nf-core/viralrecon') }}
19+
if: "${{ github.event_name != 'push' || (github.event_name == 'push' && github.repository == 'nf-core/viralrecon') }}"
2020
runs-on: ubuntu-latest
2121
strategy:
2222
matrix:
2323
# Nextflow versions
2424
include:
2525
# Test pipeline minimum Nextflow version
26-
- NXF_VER: '21.10.3'
27-
NXF_EDGE: ''
26+
- NXF_VER: "21.10.3"
27+
NXF_EDGE: ""
2828
# Test latest edge release of Nextflow
29-
- NXF_VER: ''
30-
NXF_EDGE: '1'
29+
- NXF_VER: ""
30+
NXF_EDGE: "1"
3131
steps:
3232
- name: Check out pipeline code
3333
uses: actions/checkout@v2

.github/workflows/fix-linting.yml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
name: Fix linting from a comment
2+
on:
3+
issue_comment:
4+
types: [created]
5+
6+
jobs:
7+
deploy:
8+
# Only run if comment is on a PR with the main repo, and if it contains the magic keywords
9+
if: >
10+
contains(github.event.comment.html_url, '/pull/') &&
11+
contains(github.event.comment.body, '@nf-core-bot fix linting') &&
12+
github.repository == 'nf-core/viralrecon'
13+
runs-on: ubuntu-latest
14+
steps:
15+
# Use the @nf-core-bot token to check out so we can push later
16+
- uses: actions/checkout@v3
17+
with:
18+
token: ${{ secrets.nf_core_bot_auth_token }}
19+
20+
# Action runs on the issue comment, so we don't get the PR by default
21+
# Use the gh cli to check out the PR
22+
- name: Checkout Pull Request
23+
run: gh pr checkout ${{ github.event.issue.number }}
24+
env:
25+
GITHUB_TOKEN: ${{ secrets.nf_core_bot_auth_token }}
26+
27+
- uses: actions/setup-node@v2
28+
29+
- name: Install Prettier
30+
run: npm install -g prettier @prettier/plugin-php
31+
32+
# Check that we actually need to fix something
33+
- name: Run 'prettier --check'
34+
id: prettier_status
35+
run: |
36+
if prettier --check ${GITHUB_WORKSPACE}; then
37+
echo "::set-output name=result::pass"
38+
else
39+
echo "::set-output name=result::fail"
40+
fi
41+
42+
- name: Run 'prettier --write'
43+
if: steps.prettier_status.outputs.result == 'fail'
44+
run: prettier --write ${GITHUB_WORKSPACE}
45+
46+
- name: Commit & push changes
47+
if: steps.prettier_status.outputs.result == 'fail'
48+
run: |
49+
git config user.email "core@nf-co.re"
50+
git config user.name "nf-core-bot"
51+
git config push.default upstream
52+
git add .
53+
git status
54+
git commit -m "[automated] Fix linting with Prettier"
55+
git push

.github/workflows/linting.yml

Lines changed: 13 additions & 71 deletions
Original file line numberDiff line numberDiff line change
@@ -1,49 +1,14 @@
11
name: nf-core linting
22
# This workflow is triggered on pushes and PRs to the repository.
3-
# It runs the `nf-core lint` and markdown lint tests to ensure that the code meets the nf-core guidelines
3+
# It runs the `nf-core lint` and markdown lint tests to ensure
4+
# that the code meets the nf-core guidelines.
45
on:
56
push:
67
pull_request:
78
release:
89
types: [published]
910

1011
jobs:
11-
Markdown:
12-
runs-on: ubuntu-latest
13-
steps:
14-
- uses: actions/checkout@v2
15-
- uses: actions/setup-node@v2
16-
- name: Install markdownlint
17-
run: npm install -g markdownlint-cli
18-
- name: Run Markdownlint
19-
run: markdownlint .
20-
21-
# If the above check failed, post a comment on the PR explaining the failure
22-
- name: Post PR comment
23-
if: failure()
24-
uses: mshick/add-pr-comment@v1
25-
with:
26-
message: |
27-
## Markdown linting is failing
28-
29-
To keep the code consistent with lots of contributors, we run automated code consistency checks.
30-
To fix this CI test, please run:
31-
32-
* Install `markdownlint-cli`
33-
* On Mac: `brew install markdownlint-cli`
34-
* Everything else: [Install `npm`](https://www.npmjs.com/get-npm) then [install `markdownlint-cli`](https://www.npmjs.com/package/markdownlint-cli) (`npm install -g markdownlint-cli`)
35-
* Fix the markdown errors
36-
* Automatically: `markdownlint . --fix`
37-
* Manually resolve anything left from `markdownlint .`
38-
39-
Once you push these changes the test should pass, and you can hide this comment :+1:
40-
41-
We highly recommend setting up markdownlint in your code editor so that this formatting is done automatically on save. Ask about it on Slack for help!
42-
43-
Thanks again for your contribution!
44-
repo-token: ${{ secrets.GITHUB_TOKEN }}
45-
allow-repeats: false
46-
4712
EditorConfig:
4813
runs-on: ubuntu-latest
4914
steps:
@@ -55,47 +20,24 @@ jobs:
5520
run: npm install -g editorconfig-checker
5621

5722
- name: Run ECLint check
58-
run: editorconfig-checker -exclude README.md $(git ls-files | grep -v test)
23+
run: editorconfig-checker -exclude README.md $(find .* -type f | grep -v '.git\|.py\|.md\|json\|yml\|yaml\|html\|css\|work\|.nextflow\|build\|nf_core.egg-info\|log.txt\|Makefile')
5924

60-
YAML:
25+
Prettier:
6126
runs-on: ubuntu-latest
6227
steps:
63-
- uses: actions/checkout@v1
64-
- uses: actions/setup-node@v2
65-
- name: Install yaml-lint
66-
run: npm install -g yaml-lint
67-
- name: Run yaml-lint
68-
run: yamllint $(find ${GITHUB_WORKSPACE} -type f -name "*.yml" -o -name "*.yaml") -c ${GITHUB_WORKSPACE}/.yamllint.yml
69-
70-
# If the above check failed, post a comment on the PR explaining the failure
71-
- name: Post PR comment
72-
if: failure()
73-
uses: mshick/add-pr-comment@v1
74-
with:
75-
message: |
76-
## YAML linting is failing
77-
78-
To keep the code consistent with lots of contributors, we run automated code consistency checks.
79-
To fix this CI test, please run:
80-
81-
* Install `yaml-lint`
82-
* [Install `npm`](https://www.npmjs.com/get-npm) then [install `yaml-lint`](https://www.npmjs.com/package/yaml-lint) (`npm install -g yaml-lint`)
83-
* Fix the markdown errors
84-
* Run the test locally: `yamllint $(find . -type f -name "*.yml" -o -name "*.yaml") -c ./.yamllint.yml`
85-
* Fix any reported errors in your YAML files
28+
- uses: actions/checkout@v2
8629

87-
Once you push these changes the test should pass, and you can hide this comment :+1:
30+
- uses: actions/setup-node@v2
8831

89-
We highly recommend setting up yaml-lint in your code editor so that this formatting is done automatically on save. Ask about it on Slack for help!
32+
- name: Install Prettier
33+
run: npm install -g prettier
9034

91-
Thanks again for your contribution!
92-
repo-token: ${{ secrets.GITHUB_TOKEN }}
93-
allow-repeats: false
35+
- name: Run Prettier --check
36+
run: prettier --check ${GITHUB_WORKSPACE}
9437

9538
nf-core:
9639
runs-on: ubuntu-latest
9740
steps:
98-
9941
- name: Check out pipeline code
10042
uses: actions/checkout@v2
10143

@@ -106,10 +48,10 @@ jobs:
10648
wget -qO- get.nextflow.io | bash
10749
sudo mv nextflow /usr/local/bin/
10850
109-
- uses: actions/setup-python@v1
51+
- uses: actions/setup-python@v3
11052
with:
111-
python-version: '3.6'
112-
architecture: 'x64'
53+
python-version: "3.6"
54+
architecture: "x64"
11355

11456
- name: Install dependencies
11557
run: |

0 commit comments

Comments
 (0)