Skip to content

Latest commit

 

History

History
124 lines (79 loc) · 3.05 KB

File metadata and controls

124 lines (79 loc) · 3.05 KB

Contributing

Thank you for your interest in contributing! 🤗

This file covers:

  • 🐞 Workflow for bug reports, feature requests and documentation improvements
  • 🚀 Workflow for code contributions (bug fixes, enhancements)
  • 🛠️ Development and testing
  • 📦 Updating the package
  • 🤝 Code of conduct

🐞 Workflow for bug reports, feature requests and documentation improvements

Before opening an issue, please search existing issues to avoid duplicates. If an issue exists, you can add a comment with additional details and/or upvote (👍) the issue. If there is not an existing issue, please open one and provide as much detail as possible.

  • For feature requests or documentation improvements, please describe your suggestion clearly.
  • For bugs, include:
    • Steps to reproduce.
    • Expected and actual behaviour.
    • Environment details (operating system, R version, dependencies).
    • Relevant files (e.g. problematic .qmd files).

Handling bug reports (for maintainers):

  • Confirm reproducibility by following the reported steps.
  • Label the issue appropriately (e.g. bug).
  • Request additional information if necessary.
  • Link related issues or pull requests.
  • Once resolved, close the issue with a brief summary of the fix.

🚀 Workflow for code contributions (bug fixes, enhancements)

  1. Fork the repository and clone your fork.

  2. Create a new branch for your feature or fix:

git checkout -b my-feature
  1. Make your changes and commit them with clear, descriptive messages using the conventional commits standard.

  2. Push your branch to your fork:

git push origin my-feature
  1. Open a pull request against the main branch. Describe your changes and reference any related issues.

🛠️ Development and testing

Dependencies

Set up the R environment using renv (recommended):

renv::init()
renv::restore()

If you encounter issues restoring the exact environment, you can install dependencies from DESCRIPTION and generate your own lock file:

renv::init()
renv::install()
renv::snapshot()

Some packages (e.g. igraph) may require system libraries. For example, for Ubuntu:

sudo apt install build-essential gfortran
sudo apt install libglpk-dev libxml2-dev

Tests

Run tests:

devtools::test()

Compute test coverage:

devtools::test_coverage()

Linting

lintr::lint_dir()

📦 Updating the package

If you are a maintainer and need to publish a new release:

  1. Update NEWS.md.

  2. Update the version number in DESCRIPTION and CITATION.cff, and update the date in CITATION.cff.

  3. Create a release on GitHub, which will automatically archive to Zenodo.


🤝 Code of conduct

Please be respectful and considerate. See the code of conduct for details.