Skip to content

Commit f07f043

Browse files
authored
Merge pull request #71 from MaxUlysse/DOCS
Improve tests and docs
2 parents fc08c2e + 4db8a77 commit f07f043

27 files changed

+380
-878
lines changed

.github/CONTRIBUTING.md

Lines changed: 31 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,47 +1,57 @@
11
# nf-core/sarek: Contributing Guidelines
22

3-
Hi there! Many thanks for taking an interest in improving nf-core/sarek.
3+
Hi there!
4+
Many thanks for taking an interest in improving nf-core/sarek.
45

5-
We try to manage the required tasks for nf-core/sarek using GitHub issues, you probably came to this page when creating one. Please use the pre-filled template to save time.
6-
7-
However, don't be put off by this template - other more general issues and suggestions are welcome! Contributions to the code are even more welcome ;)
8-
9-
> If you need help using or modifying nf-core/sarek then the best place to ask is on the pipeline channel on [Slack](https://nf-core-invite.herokuapp.com/).
6+
We try to manage the required tasks for nf-core/sarek using GitHub issues, you probably came to this page when creating one.
7+
Please use the pre-filled template to save time.
108

9+
However, don't be put off by this template - other more general issues and suggestions are welcome!
10+
Contributions to the code are even more welcome ;)
1111

12+
> If you need help using or modifying nf-core/sarek then the best place to ask is on the nf-core Slack [#sarek](https://nfcore.slack.com/channels/sarek) channel ([join our Slack here](https://nf-co.re/join/slack)).
1213
1314
## Contribution workflow
14-
If you'd like to write some code for nf-core/sarek, the standard workflow
15-
is as follows:
1615

17-
1. Check that there isn't already an issue about your idea in the
18-
[nf-core/sarek issues](https://github.com/nf-core/sarek/issues) to avoid
19-
duplicating work.
16+
If you'd like to write some code for nf-core/sarek, the standard workflow is as follows:
17+
18+
1. Check that there isn't already an issue about your idea in the [nf-core/sarek issues](https://github.com/nf-core/sarek/issues) to avoid duplicating work
2019
* If there isn't one already, please create one so that others know you're working on this
21-
2. Fork the [nf-core/sarek repository](https://github.com/nf-core/sarek) to your GitHub account
20+
2. [Fork](https://help.github.com/en/github/getting-started-with-github/fork-a-repo) the [nf-core/sarek repository](https://github.com/nf-core/sarek) to your GitHub account
2221
3. Make the necessary changes / additions within your forked repository
23-
4. Submit a Pull Request against the `dev` branch and wait for the code to be reviewed and merged.
24-
25-
If you're not used to this workflow with git, you can start with some [basic docs from GitHub](https://help.github.com/articles/fork-a-repo/) or even their [excellent interactive tutorial](https://try.github.io/).
22+
4. Submit a Pull Request against the `dev` branch and wait for the code to be reviewed and merged
2623

24+
If you're not used to this workflow with git, you can start with some [docs from GitHub](https://help.github.com/en/github/collaborating-with-issues-and-pull-requests) or even their [excellent `git` resources](https://try.github.io/).
2725

2826
## Tests
29-
When you create a pull request with changes, [Travis CI](https://travis-ci.org/) will run automatic tests.
27+
28+
When you create a pull request with changes, [GitHub Actions](https://github.com/features/actions) will run automatic tests.
3029
Typically, pull-requests are only fully reviewed when these tests are passing, though of course we can help out before then.
3130

3231
There are typically two types of tests that run:
3332

3433
### Lint Tests
35-
The nf-core has a [set of guidelines](http://nf-co.re/guidelines) which all pipelines must adhere to.
34+
35+
`nf-core` has a [set of guidelines](https://nf-co.re/developers/guidelines) which all pipelines must adhere to.
3636
To enforce these and ensure that all pipelines stay in sync, we have developed a helper tool which runs checks on the pipeline code. This is in the [nf-core/tools repository](https://github.com/nf-core/tools) and once installed can be run locally with the `nf-core lint <pipeline-directory>` command.
3737

3838
If any failures or warnings are encountered, please follow the listed URL for more documentation.
3939

4040
### Pipeline Tests
41-
Each nf-core pipeline should be set up with a minimal set of test-data.
42-
Travis CI then runs the pipeline on this data to ensure that it exists successfully.
41+
42+
Each `nf-core` pipeline should be set up with a minimal set of test-data.
43+
`GitHub Actions` then runs the pipeline on this data to ensure that it exits successfully.
4344
If there are any failures then the automated tests fail.
44-
These tests are run both with the latest available version of Nextflow and also the minimum required version that is stated in the pipeline code.
45+
These tests are run both with the latest available version of `Nextflow` and also the minimum required version that is stated in the pipeline code.
46+
47+
## Patch
48+
49+
: warning: Only in the unlikely and regretful event of a release happening with a bug.
50+
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.
4554

4655
## Getting help
47-
For further information/help, please consult the [nf-core/sarek documentation](https://github.com/nf-core/sarek#documentation) and don't hesitate to get in touch on the [sarek pipeline channel](https://nfcore.slack.com/channels/sarek) on [Slack](https://nf-co.re/join/slack).
56+
57+
For further information/help, please consult the [nf-core/sarek documentation](https://nf-co.re/sarek/docs) and don't hesitate to get in touch on the nf-core Slack [#sarek](https://nfcore.slack.com/channels/sarek) channel ([join our Slack here](https://nf-co.re/join/slack)).
Lines changed: 27 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,42 @@
1+
# nf-core/sarek bug report
2+
13
Hi there!
24

3-
Thanks for telling us about a problem with the pipeline. Please delete this text and anything that's not relevant from the template below:
5+
Thanks for telling us about a problem with the pipeline.
6+
Please delete this text and anything that's not relevant from the template below:
7+
8+
## Describe the bug
49

5-
#### Describe the bug
610
A clear and concise description of what the bug is.
711

8-
#### Steps to reproduce
12+
## Steps to reproduce
13+
914
Steps to reproduce the behaviour:
15+
1016
1. Command line: `nextflow run ...`
1117
2. See error: _Please provide your error message_
1218

13-
#### Expected behaviour
19+
## Expected behaviour
20+
1421
A clear and concise description of what you expected to happen.
1522

16-
#### System:
17-
- Hardware: [e.g. HPC, Desktop, Cloud...]
18-
- Executor: [e.g. slurm, local, awsbatch...]
19-
- OS: [e.g. CentOS Linux, macOS, Linux Mint...]
20-
- Version [e.g. 7, 10.13.6, 18.3...]
23+
## System
24+
25+
- Hardware: <!-- [e.g. HPC, Desktop, Cloud...] -->
26+
- Executor: <!-- [e.g. slurm, local, awsbatch...] -->
27+
- OS: <!-- [e.g. CentOS Linux, macOS, Linux Mint...] -->
28+
- Version <!-- [e.g. 7, 10.13.6, 18.3...] -->
29+
30+
## Nextflow Installation
31+
32+
- Version: <!-- [e.g. 19.10.0] -->
33+
34+
## Container engine
2135

22-
#### Nextflow Installation:
23-
- Version: [e.g. 0.31.0]
36+
- Engine: <!-- [e.g. Conda, Docker or Singularity] -->
37+
- version: <!-- [e.g. 1.0.0] -->
38+
- Image tag: <!-- [e.g. nfcore/sarek:2.5.1] -->
2439

25-
#### Container engine:
26-
- Engine: [e.g. Conda, Docker or Singularity]
27-
- version: [e.g. 1.0.0]
28-
- Image tag: [e.g. nfcore/sarek:1.0.0]
40+
## Additional context
2941

30-
#### Additional context
3142
Add any other context about the problem here.
Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,24 @@
1+
# nf-core/sarek feature request
2+
13
Hi there!
24

3-
Thanks for suggesting a new feature for the pipeline! Please delete this text and anything that's not relevant from the template below:
5+
Thanks for suggesting a new feature for the pipeline!
6+
Please delete this text and anything that's not relevant from the template below:
7+
8+
## Is your feature request related to a problem? Please describe
49

5-
#### Is your feature request related to a problem? Please describe.
610
A clear and concise description of what the problem is.
11+
712
Ex. I'm always frustrated when [...]
813

9-
#### Describe the solution you'd like
14+
## Describe the solution you'd like
15+
1016
A clear and concise description of what you want to happen.
1117

12-
#### Describe alternatives you've considered
18+
## Describe alternatives you've considered
19+
1320
A clear and concise description of any alternative solutions or features you've considered.
1421

15-
#### Additional context
22+
## Additional context
23+
1624
Add any other context about the feature request here.

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 13 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,19 @@
1-
Many thanks to contributing to nf-core/sarek!
1+
# nf-core/sarek pull request
2+
3+
Many thanks for contributing to nf-core/sarek!
24

35
Please fill in the appropriate checklist below (delete whatever is not relevant).
46
These are the most common things requested on pull requests (PRs).
57

68
## PR checklist
7-
- [ ] This comment contains a description of changes (with reason)
8-
- [ ] If you've fixed a bug or added code that should be tested, add tests!
9-
- [ ] If necessary, also make a PR on the [nf-core/sarek branch on the nf-core/test-datasets repo](https://github.com/nf-core/test-datasets/pull/new/nf-core/sarek)
10-
- [ ] Ensure the test suite passes (`nextflow run . -profile test,docker`).
11-
- [ ] Make sure your code lints (`nf-core lint .`).
12-
- [ ] Documentation in `docs` is updated
13-
- [ ] `CHANGELOG.md` is updated
14-
- [ ] `README.md` is updated
159

16-
**Learn more about contributing:** [guidelines](https://github.com/nf-core/sarek/tree/master/.github/CONTRIBUTING.md)
10+
- [ ] This comment contains a description of changes (with reason)
11+
- [ ] If you've fixed a bug or added code that should be tested, add tests!
12+
- [ ] If necessary, also make a PR on the [nf-core/sarek branch on the nf-core/test-datasets repo](https://github.com/nf-core/test-datasets/pull/new/nf-core/sarek)
13+
- [ ] Ensure the test suite passes (`nextflow run . -profile test,docker`).
14+
- [ ] Make sure your code lints (`nf-core lint .`).
15+
- [ ] Documentation in `docs` is updated
16+
- [ ] `CHANGELOG.md` is updated
17+
- [ ] `README.md` is updated
18+
19+
**Learn more about contributing:** [CONTRIBUTING.md](https://github.com/nf-core/sarek/tree/master/.github/CONTRIBUTING.md)

.github/workflows/branch.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@ on:
77

88
jobs:
99
test:
10-
runs-on: ubuntu-latest
10+
runs-on: ubuntu-18.04
1111
steps:
1212
# PRs are only ok if coming from an nf-core dev branch
1313
- uses: actions/checkout@v1
1414
- name: Check PRs
1515
run: |
16-
{ [[ $(git remote get-url origin) == *nf-core/sarek ]] && [[ ${GITHUB_BASE_REF} = "master" ]] && [[ ${GITHUB_HEAD_REF} = "dev" ]]; } || [[ ${GITHUB_HEAD_REF} == patch* ]]
16+
{ [[ $(git remote get-url origin) == *nf-core/sarek ]] && [[ ${GITHUB_HEAD_REF} = "dev" ]]; } || [[ ${GITHUB_HEAD_REF} == "patch" ]]

.github/workflows/ci-extra.yml

Lines changed: 49 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,22 +3,64 @@ name: sarek extra CI
33
on: [push, pull_request]
44

55
jobs:
6-
test:
7-
runs-on: ubuntu-latest
6+
profile:
7+
runs-on: ubuntu-18.04
88
strategy:
99
matrix:
10-
test: [ANNOTATESNPEFF, GERMLINE, SOMATIC, SPLITFASTQ, TARGETED]
11-
nxf_ver: ['19.04.0', '']
10+
profile: [test_splitfastq, test_targeted]
1211
steps:
1312
- uses: actions/checkout@v1
1413
- name: Install Nextflow
1514
run: |
16-
export NXF_VER=${{ matrix.nxf_ver }}
1715
wget -qO- get.nextflow.io | bash
1816
sudo mv nextflow /usr/local/bin/
17+
env:
18+
NXF_VER: '19.04.0'
1919
- name: Download image
2020
run: |
21-
${GITHUB_WORKSPACE}/scripts/download_image.sh -n docker --source-version dev --target-version dev --test ${{ matrix.test }}
21+
docker pull nfcore/sarek:dev
22+
docker tag nfcore/sarek:dev nfcore/sarek:dev
2223
- name: Run test
2324
run: |
24-
${GITHUB_WORKSPACE}/scripts/run_tests.sh --test ${{ matrix.test }} --verbose
25+
nextflow run . -profile ${{ matrix.profile }},docker --verbose
26+
tools:
27+
runs-on: ubuntu-18.04
28+
strategy:
29+
matrix:
30+
tool: [Haplotypecaller, Freebayes, Manta, mpileup, Mutect2, Strelka]
31+
steps:
32+
- uses: actions/checkout@v1
33+
- name: Install Nextflow
34+
run: |
35+
wget -qO- get.nextflow.io | bash
36+
sudo mv nextflow /usr/local/bin/
37+
env:
38+
NXF_VER: '19.04.0'
39+
- name: Download image
40+
run: |
41+
docker pull nfcore/sarek:dev
42+
docker tag nfcore/sarek:dev nfcore/sarek:dev
43+
- name: Run test
44+
run: |
45+
nextflow run . -profile test_tool,docker --verbose --tools ${{ matrix.tool }}
46+
annotation:
47+
runs-on: ubuntu-18.04
48+
strategy:
49+
matrix:
50+
annotator: [snpeff]
51+
specie: [GRCh37]
52+
steps:
53+
- uses: actions/checkout@v1
54+
- name: Install Nextflow
55+
run: |
56+
wget -qO- get.nextflow.io | bash
57+
sudo mv nextflow /usr/local/bin/
58+
env:
59+
NXF_VER: '19.04.0'
60+
- name: Download image
61+
run: |
62+
docker pull nfcore/sarek${{ matrix.annotator }}:dev.${{ matrix.specie }}
63+
docker tag nfcore/sarek${{ matrix.annotator }}:dev.${{ matrix.specie }} nfcore/sarek${{ matrix.annotator }}:dev.${{ matrix.specie }}
64+
- name: Run test
65+
run: |
66+
nextflow run . -profile test_annotation,docker --verbose --tools ${{ matrix.annotator }}

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ on: [push, pull_request]
44

55
jobs:
66
test:
7-
runs-on: ubuntu-latest
7+
runs-on: ubuntu-18.04
88
strategy:
99
matrix:
1010
nxf_ver: ['19.04.0', '']

.github/workflows/linting.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ on: [push, pull_request]
44

55
jobs:
66
Markdown:
7-
runs-on: ubuntu-latest
7+
runs-on: ubuntu-18.04
88
steps:
99
- uses: actions/checkout@v1
1010
- uses: actions/setup-node@v1
@@ -17,7 +17,7 @@ jobs:
1717
run: |
1818
markdownlint ${GITHUB_WORKSPACE} -c ${GITHUB_WORKSPACE}/.github/markdownlint.yml
1919
YAML:
20-
runs-on: ubuntu-latest
20+
runs-on: ubuntu-18.04
2121
steps:
2222
- uses: actions/checkout@v1
2323
- uses: actions/setup-node@v1
@@ -30,7 +30,7 @@ jobs:
3030
run: |
3131
yamllint $(find ${GITHUB_WORKSPACE} -type f -name "*.yml")
3232
nf-core:
33-
runs-on: ubuntu-latest
33+
runs-on: ubuntu-18.04
3434
steps:
3535
- uses: actions/checkout@v1
3636
- name: Install Nextflow

0 commit comments

Comments
 (0)