From 19243bfc9f9e12409006c982bd407ab3b820e786 Mon Sep 17 00:00:00 2001 From: ClementTsang Date: Tue, 28 Apr 2020 22:54:50 -0400 Subject: [PATCH] docs: Add CONTRIBUTING.md --- .github/ISSUE_TEMPLATE/bug_report.md | 2 + .github/pull_request_template.md | 2 +- CONTRIBUTING.md | 73 ++++++++++++++++++++++++++++ README.md | 7 +-- 4 files changed, 77 insertions(+), 7 deletions(-) create mode 100644 CONTRIBUTING.md diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index d5a1cb56..130cfd35 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -27,6 +27,8 @@ _If relevant, please provide information on:_ **Shell:** +**bottom version (use `btm -V`):** + **Any other relevant information (more details are always good!):** ## Additional context diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index 1ad95560..71238a90 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -37,7 +37,7 @@ _If relevant, see if the following have been met:_ - [ ] _Code has been self-reviewed_ - [ ] _Code has been tested and no new breakage is introduced unless intended_ - [ ] _Passes CI tests_ -- [ ] _Documentation has been added/updated if needed_ +- [ ] _Documentation has been added/updated if needed (README, help menu, etc.)_ - [ ] _No merge conflicts arise from the change_ ## Other information diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 00000000..c616a359 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,73 @@ +# Contribution + +If you want to contribute to this project - first of all, thank you! I'm glad to see +interest in it! + +Here are some notes about how to contribute to bottom (structure is based on the official +[Rust contribution guidelines](https://github.com/rust-lang/rust/blob/master/CONTRIBUTING.md)): + +- [Feature reports](#feature-reports) +- [Bug reports](#bug-reports) +- [Other types of reports](#other-types-of-reports) +- [Pull requests](#pull-requests) + +## Feature reports + +Feature suggestions can be submitted via [GitHub Issues](https://github.com/ClementTsang/bottom/issues) using the "feature" tag. +Prior to submission, please look to see if this has already been suggested or solved; if it has and is not resolved, +it would be better to comment on the relevant report. + +Within your feature report, try to answer the given prompts - in particular, state the specific feature you want and if possible, +please state why you want this added to the program. + +## Bug reports + +Bug reports can be submitted via [GitHub Issues](https://github.com/ClementTsang/bottom/issues) using the "bug" tag. +Prior to submission, please look to see if this has already been reported or solved; if it has and is not resolved, +it would be better to comment on the relevant report. + +Within your bug report, try to answer the given prompts. Be as specific as possible - describe your bug to the best of your ability, how +to replicate it, and provide information like screenshots, OS and terminal. It can be very useful to help whoever is dealing with the issue! + +## Other types of reports + +For reports/suggestions that don't fit the definition of a feature or bug, try to use the other tags: + +- documentation: If you note a typo, or want to suggest something to do with the documentation of bottom, use this. +- question: If you have a question, and not really a suggestion or request, then use this tag. +- ci, investigative, refactoring: Generally, these are for internal use to track issues in order to manage GitHub Projects, and won't be the appropriate topic for a report. +- other: If your suggestion doesn't fit those categories, then use this. + +## Pull requests + +If you want to help contribute by submitting a PR, by all means, I'm open! In regards to the development process: + +- I develop primarily using _stable_ Rust. That is, whatever is the most up-to-date stable version you can get via running + `rustup update stable`. + +- I use both [clippy](https://github.com/rust-lang/rust-clippy) and [rustfmt](https://github.com/rust-lang/rustfmt) in development (with some settings, see [clippy.toml](./clippy.toml) and [rustfmt.toml](rustfmt.toml)). Note clippy must pass to pass CI. + + - You can check clippy using `cargo +nightly clippy`. + +And in regards to the pull request process: + +- Create a personal fork of the process and PR that, as per the [fork and pull method](https://help.github.com/en/github/collaborating-with-issues-and-pull-requests/about-collaborative-development-models). + +- Merge against the `master` branch. + +- If you encounter a merge conflict, I expect you to resolve this via rebasing to `master`. + +- _Ensure your change builds, runs, and works_. Furthermore, state how you checked this, including what platforms you tested on. + +- If your change will result in needing to update documentation, please do so. In particular: + + - Does the README need to be updated to accommodate your change? + + - Does the help action, `?`, need to be updated to accommodate your change? + +- Please ensure that CI passes. If it fails, check to see why it fails! Chances are it's clippy. + +- If all looks good, then request someone with write access (so basically me, [@ClementTsang](https://github.com/ClementTsang)) to give your code a review. If it's fine, then I'll merge! + +- Please use the [pull request template](https://github.com/ClementTsang/bottom/blob/master/.github/pull_request_template.md) to + help you in this process. diff --git a/README.md b/README.md index caf64724..3f7835a7 100644 --- a/README.md +++ b/README.md @@ -463,7 +463,7 @@ The current compatibility of widgets with operating systems from personal testin ## Contribution -Contribution is always welcome - just submit a PR! Note that I currently develop and test on stable Rust. +Contribution is always welcome - please take a look at [CONTRIBUTING.md](./CONTRIBUTING.md) for details on how to help. Thanks to all contributors ([emoji key](https://allcontributors.org/docs/en/emoji-key)): @@ -483,11 +483,6 @@ Thanks to all contributors ([emoji key](https://allcontributors.org/docs/en/emoj -## Bug reports and feature requests - -Feel free to submit feature ideas and bug reports on [GitHub](https://github.com/ClementTsang/bottom/issues). -Please try to follow the given issue templates. - ## Thanks - This project is very much inspired by both