Skip to content
Snippets Groups Projects
CONTRIBUTING.md 3.32 KiB
Newer Older
nservant's avatar
nservant committed
# nf-core/hic: Contributing Guidelines

Hi there!
Many thanks for taking an interest in improving nf-core/hic.
nservant's avatar
nservant committed

We try to manage the required tasks for nf-core/hic using GitHub issues, you probably came to this page when creating one.
Please use the pre-filled template to save time.
nservant's avatar
nservant committed

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 ;)
nservant's avatar
nservant committed

> If you need help using or modifying nf-core/hic then the best place to ask is on the nf-core
Slack [#hic](https://nfcore.slack.com/channels/hic) channel ([join our Slack here](https://nf-co.re/join/slack)).
nservant's avatar
nservant committed


## Contribution workflow

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

1. Check that there isn't already an issue about your idea in the [nf-core/hic issues](https://github.com/nf-core/hic/issues) to avoid duplicating work
nservant's avatar
nservant committed
    * If there isn't one already, please create one so that others know you're working on this
2. [Fork](https://help.github.com/en/github/getting-started-with-github/fork-a-repo) the [nf-core/hic repository](https://github.com/nf-core/hic) to your GitHub account
nservant's avatar
nservant committed
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
nservant's avatar
nservant committed

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/).
nservant's avatar
nservant committed

## Tests

When you create a pull request with changes, [GitHub Actions](https://github.com/features/actions) will run automatic tests.
nservant's avatar
nservant committed
Typically, pull-requests are only fully reviewed when these tests are passing, though of course we can help out before then.

There are typically two types of tests that run:

### Lint Tests

`nf-core` has a [set of guidelines](https://nf-co.re/developers/guidelines) which all pipelines must adhere to.
nservant's avatar
nservant committed
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.

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

### Pipeline Tests

Each `nf-core` pipeline should be set up with a minimal set of test-data.
`GitHub Actions` then runs the pipeline on this data to ensure that it exits successfully.
nservant's avatar
nservant committed
If there are any failures then the automated tests fail.
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.

## Patch

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

* On your own fork, make a new branch `patch` based on `upstream/master`.
* Fix the bug, and bump version (X.Y.Z+1).
* A PR should be made on `master` from patch to directly this particular bug.
nservant's avatar
nservant committed

## Getting help
For further information/help, please consult the [nf-core/hic documentation](https://nf-co.re/nf-core/hic/docs) and
don't hesitate to get in touch on the nf-core Slack [#hic](https://nfcore.slack.com/channels/hic) channel
([join our Slack here](https://nf-co.re/join/slack)).