Skip to content

Commit

Permalink
Merge pull request #1483 from nf-core/dev
Browse files Browse the repository at this point in the history
Dev > Master for v2.3.1
  • Loading branch information
ewels authored Mar 23, 2022
2 parents b1ce471 + ab0b99d commit 27c98a1
Show file tree
Hide file tree
Showing 128 changed files with 2,131 additions and 1,676 deletions.
12 changes: 12 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
root = true

[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
indent_size = 4
indent_style = space

[*.{md,yml,yaml,html,css,scss,js}]
indent_size = 2
4 changes: 2 additions & 2 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ If you'd like to write some code for nf-core/tools, the standard workflow
is as follows:

1. Check that there isn't [already an issue](https://github.com/nf-core/tools/issues) about your idea to avoid duplicating work.
* If there isn't one already, please create one so that others know you're working on this
- If there isn't one already, please create one so that others know you're working on this
2. Fork the [nf-core/tools repository](https://github.com/nf-core/tools) to your GitHub account
3. Make the necessary changes / additions within your forked repository
4. Submit a Pull Request against the `dev` branch and wait for the code to be reviewed and merged.
Expand Down Expand Up @@ -75,7 +75,7 @@ New features should also come with new tests, to keep the test-coverage high (we
You can try running the tests locally before pushing code using the following command:

```bash
pytest --color=yes tests/
pytest --color=yes
```

### Lint Tests
Expand Down
1 change: 0 additions & 1 deletion .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ name: Bug report
description: Report something that is broken or incorrect
labels: bug
body:

- type: markdown
attributes:
value: |
Expand Down
8 changes: 4 additions & 4 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Learn more about contributing: https://github.com/nf-core/tools/tree/master/.git

## PR checklist

- [ ] This comment contains a description of changes (with reason)
- [ ] `CHANGELOG.md` is updated
- [ ] If you've fixed a bug or added code that should be tested, add tests!
- [ ] Documentation in `docs` is updated
- [ ] This comment contains a description of changes (with reason)
- [ ] `CHANGELOG.md` is updated
- [ ] If you've fixed a bug or added code that should be tested, add tests!
- [ ] Documentation in `docs` is updated
10 changes: 6 additions & 4 deletions .github/RELEASE_CHECKLIST.md
Original file line number Diff line number Diff line change
@@ -1,19 +1,21 @@
## Before release

1. Check issue milestones to see outstanding issues to resolve if possible or transfer to the milestones for the next release e.g. [`v1.9`](https://github.com/nf-core/tools/issues?q=is%3Aopen+is%3Aissue+milestone%3A1.9)
2. Most importantly, pick an undeniably outstanding [name](http://www.codenamegenerator.com/) for the release where *Prefix* = *Metal* and *Dictionary* = *Animal*.
2. Most importantly, pick an undeniably outstanding [name](http://www.codenamegenerator.com/) for the release where _Prefix_ = _Metal_ and _Dictionary_ = _Animal_.
3. Check whether the GitHub Actions workflow scripts need updating of the Nextflow versions
4. Create a PR to `dev` to bump the version in `CHANGELOG.md` and `setup.py`.
4. Create a PR to `dev` to bump the version in `CHANGELOG.md` and `setup.py`.
5. Make sure all CI tests are passing!
6. Create a PR from `dev` to `master`
7. Make sure all CI tests are passing again (additional tests are run on PRs to `master`)
8. Request review (2 approvals required)
9. Merge the PR into `master`
10. Once CI tests on commit have passed, create a new release copying the `CHANGELOG` for that release into the description section.
10. Wait for CI tests on the commit to passed
11. (Optional but a good idea) Run a manual sync on `nf-core/testpipeline` and check that CI is passing on the resulting PR.
12. Create a new release copying the `CHANGELOG` for that release into the description section.

## After release

1. Check the automated template synchronisation has been triggered properly. This should automatically open PRs directly to individual pipeline repos with the appropriate changes to update the pipeline template.
2. Check that the automatic `PyPi` deployment has worked: [pypi.org/project/nf-core](https://pypi.org/project/nf-core/)
3. Check `BioConda` has an automated PR to bump the version, and merge. eg. [bioconda/bioconda-recipes #20065](https://github.com/bioconda/bioconda-recipes/pull/20065)
4. Create a tools PR to `dev` to bump back to the next development version in `CHANGELOG.md` and `setup.py`
4. Create a tools PR to `dev` to bump back to the next development version in `CHANGELOG.md` and `setup.py`
45 changes: 0 additions & 45 deletions .github/workflows/build_gitpod.yml

This file was deleted.

48 changes: 40 additions & 8 deletions .github/workflows/create-lint-wf.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Create a pipeline and lint it
name: Create a pipeline and run nf-core linting
on: [push, pull_request]

env:
Expand All @@ -15,15 +15,17 @@ jobs:
# Nextflow versions
include:
# Test pipeline minimum Nextflow version
- NXF_VER: '21.10.3'
NXF_EDGE: ''
- NXF_VER: "21.10.3"
NXF_EDGE: ""
# Test latest edge release of Nextflow
- NXF_VER: ''
NXF_EDGE: '1'
- NXF_VER: ""
NXF_EDGE: "1"
steps:
# Get the repo code
- uses: actions/checkout@v2
name: Check out source-code repository

# Set up nf-core/tools
- name: Set up Python 3.8
uses: actions/setup-python@v1
with:
Expand All @@ -34,6 +36,7 @@ jobs:
python -m pip install --upgrade pip
pip install .
# Set up Nextflow
- name: Install Nextflow
env:
NXF_VER: ${{ matrix.NXF_VER }}
Expand All @@ -44,21 +47,50 @@ jobs:
wget -qO- get.nextflow.io | bash
sudo mv nextflow /usr/local/bin/
# Install the Prettier linting tools
- uses: actions/setup-node@v2

- name: Install Prettier
run: npm install -g prettier

# Install the editorconfig linting tools
- name: Install editorconfig-checker
run: npm install -g editorconfig-checker

# Build a pipeline from the template
- name: nf-core create
run: nf-core --log-file log.txt create -n testpipeline -d "This pipeline is for testing" -a "Testing McTestface"

# Try syncing it before we change anything
- name: nf-core sync
run: nf-core --log-file log.txt sync --dir nf-core-testpipeline/

# Build a module from the template
- name: nf-core modules create
run: nf-core --log-file log.txt modules create bpipe --dir nf-core-testpipeline --author @nf-core-bot --label process_low --meta

# Run code style linting
- name: Run Prettier --check
run: prettier --check nf-core-testpipeline

- name: Run ECLint check
run: editorconfig-checker -exclude README.md $(find nf-core-testpipeline/.* -type f | grep -v '.git\|.py\|md\|json\|yml\|yaml\|html\|css\|work\|.nextflow\|build\|nf_core.egg-info\|log.txt\|Makefile')

# Update modules to the latest version
- name: nf-core modules update
run: nf-core --log-file log.txt modules update --dir nf-core-testpipeline --all --no-preview

# Run nf-core linting
- name: nf-core lint
run: nf-core --log-file log.txt lint --dir nf-core-testpipeline --fail-ignored

# Run the other nf-core commands
- name: nf-core list
run: nf-core --log-file log.txt list

# - name: nf-core licences
# run: nf-core --log-file log.txt licences nf-core-testpipeline

- name: nf-core sync
run: nf-core --log-file log.txt sync --dir nf-core-testpipeline/

- name: nf-core schema
run: nf-core --log-file log.txt schema build --dir nf-core-testpipeline/ --no-prompts

Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/create-test-wf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ jobs:
# Nextflow versions
include:
# Test pipeline minimum Nextflow version
- NXF_VER: '21.10.3'
NXF_EDGE: ''
- NXF_VER: "21.10.3"
NXF_EDGE: ""
# Test latest edge release of Nextflow
- NXF_VER: ''
NXF_EDGE: '1'
- NXF_VER: ""
NXF_EDGE: "1"
steps:
- uses: actions/checkout@v2
name: Check out source-code repository
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,35 @@
name: Lint Python
on:
push:
paths:
- '**.py'
pull_request:
paths:
- '**.py'
name: Lint tools code formatting
on: [push, pull_request]

jobs:
PythonLint:
EditorConfig:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- uses: actions/setup-node@v2

- name: Install editorconfig-checker
run: npm install -g editorconfig-checker

# Run editor config check only on files not covered by a linter
- name: Run ECLint check
run: editorconfig-checker -exclude README.md $(git ls-files | grep -v 'test\|.py\|md\|json\|yml\|yaml\|html\|css\|Makefile')

Prettier:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- uses: actions/setup-node@v2

- name: Install Prettier
run: npm install -g prettier

- name: Run Prettier --check
run: prettier --check ${GITHUB_WORKSPACE}

PythonBlack:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
Expand Down
42 changes: 0 additions & 42 deletions .github/workflows/markdown-lint.yml

This file was deleted.

8 changes: 6 additions & 2 deletions .github/workflows/push_dockerhub_dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,14 @@ jobs:
- name: Check out code
uses: actions/checkout@v2

- name: Build new docker image
- name: Build nfcore/tools:dev docker image
run: docker build --no-cache . -t nfcore/tools:dev

- name: Push Docker image to DockerHub (dev)
- name: Build nfcore/gitpod:dev docker image
run: docker build --no-cache . --file nf_core/gitpod/gitpod.Dockerfile -t nfcore/gitpod:dev

- name: Push Docker images to DockerHub (dev)
run: |
echo "$DOCKERHUB_PASS" | docker login -u "$DOCKERHUB_USERNAME" --password-stdin
docker push nfcore/tools:dev
docker push nfcore/gitpod:dev
10 changes: 8 additions & 2 deletions .github/workflows/push_dockerhub_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,18 @@ jobs:
- name: Check out code
uses: actions/checkout@v2

- name: Build new docker image
- name: Build nfcore/tools:latest docker image
run: docker build --no-cache . -t nfcore/tools:latest

- name: Push Docker image to DockerHub (release)
- name: Build nfcore/gitpod:latest docker image
run: docker build --no-cache . --file nf_core/gitpod/gitpod.Dockerfile -t nfcore/gitpod:latest

- name: Push Docker images to DockerHub (release)
run: |
echo "$DOCKERHUB_PASS" | docker login -u "$DOCKERHUB_USERNAME" --password-stdin
docker push nfcore/tools:latest
docker tag nfcore/tools:latest nfcore/tools:${{ github.event.release.tag_name }}
docker push nfcore/tools:${{ github.event.release.tag_name }}
docker push nfcore/gitpod:latest
docker tag nfcore/gitpod:latest nfcore/tools:${{ github.event.release.tag_name }}
docker push nfcore/gitpod:${{ github.event.release.tag_name }}
2 changes: 1 addition & 1 deletion .github/workflows/pytest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.6', '3.7', '3.8', '3.9', '3.10']
python-version: ["3.6", "3.7", "3.8", "3.9", "3.10"]

steps:
- uses: actions/checkout@v2
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/tools-api-docs-dev.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
name: nf-core/tools dev API docs
on:
push:
branches: [dev]
# Run on push and PR to test that docs build
on: [pull_request, push]

jobs:
api-docs:
Expand All @@ -27,13 +26,14 @@ jobs:
run: make --directory ./docs/api html

- name: Sync dev docs
if: github.repository == 'nf-core/tools'
# Only sync with the website if it was a push from nf-core/tools dev branch
if: github.repository == 'nf-core/tools' && github.event_name == 'push' && github.event.ref == 'refs/heads/dev'
uses: SamKirkland/FTP-Deploy-Action@4.0.0
with:
server: ${{ secrets.ftp_server }}
username: ${{ secrets.ftp_username}}
password: ${{ secrets.ftp_password }}
local-dir: './docs/api/_build/html/'
local-dir: "./docs/api/_build/html/"
server-dir: ${{ secrets.ftp_server_dir }}/dev/
protocol: ${{ secrets.ftp_protocol }}
port: ${{ secrets.ftp_port }}
2 changes: 1 addition & 1 deletion .github/workflows/tools-api-docs-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ jobs:
server: ${{ secrets.ftp_server }}
username: ${{ secrets.ftp_username}}
password: ${{ secrets.ftp_password }}
local-dir: './docs/api/_build/html/'
local-dir: "./docs/api/_build/html/"
server-dir: ${{ secrets.ftp_server_dir }}/${{ matrix.dir }}/
protocol: ${{ secrets.ftp_protocol }}
port: ${{ secrets.ftp_port }}
Loading

0 comments on commit 27c98a1

Please sign in to comment.