Skip to content

Commit ce22ed6

Browse files
committed
Add templates
1 parent aadca2a commit ce22ed6

File tree

3 files changed

+118
-0
lines changed

3 files changed

+118
-0
lines changed

.github/ISSUE_TEMPLATE.md

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
Use one of the two templates below and **delete the rest**.
2+
3+
8<------------------------ BUG REPORT -----------------------------------------
4+
### Expected behavior
5+
6+
### Actual behavior
7+
8+
```
9+
Add serial console output here
10+
```
11+
12+
### Test code
13+
Provide a [Minimal, Complete, and Verifiable example](http://stackoverflow.com/help/mcve) which will reproduce the problem.
14+
15+
```c
16+
// add code here
17+
```
18+
### Weather Station version
19+
Which branch are you on? If you know the Git revision then add it here as well.
20+
21+
### Hardware
22+
Describe whether you run the code on the ThingPulse Weather Station Color kit or on some custom hardware.
23+
24+
8<------------------------ END BUG REPORT -------------------------------------
25+
26+
27+
8<------------------------ FEATURE REQUEST ------------------------------------
28+
### Missing feature
29+
30+
### Justification
31+
Tell us why you would like to see this feature added.
32+
33+
### Workarounds
34+
Are there any workarounds you currently have in place because the feature is missing?
35+
36+
8<------------------------ END FEATURE REQUEST --------------------------------

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
Fixes #\<GitHub-issue-number\>.
2+
3+
Make sure all boxes are checked (add x inside the brackets) when you submit your contribution, remove this sentence before doing so.
4+
5+
- [ ] This PR is compliant with the [other contributing guidelines](https://github.com/ThingPulse/esp8266-weather-station/blob/master/CONTRIBUTING.md) as well (if not, please describe why).
6+
- [ ] I have thoroughly tested my contribution.
7+
- [ ] Should this code require changes to documentation I will contribute those to [https://github.com/ThingPulse/docs](https://github.com/ThingPulse/docs).
8+
9+
\<Description of and rationale behind this PR\>

CONTRIBUTING.md

Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
# Contributing to ThingPulse Weather Station
2+
3+
:+1::tada: First off, thanks for taking the time to contribute! :tada::+1:
4+
5+
The following is a set of guidelines for contributing to the ThingPulse Weather Station project on GitHub. These are just guidelines, not rules, use your best judgment and feel free to propose changes to this document in a pull request.
6+
7+
It is appreciated if you raise an issue _before_ you start changing the code, discussing the proposed change; emphasizing that you are proposing to develop the patch yourself, and outlining the strategy for implementation. This type of discussion is what we should be doing on the issues list and it is better to do this before or in parallel to developing the patch rather than having "you should have done it this way" type of feedback on the PR itself.
8+
9+
### Table Of Contents
10+
* [General remarks](#general-remarks)
11+
* [Writing Documentation](#writing-documentation)
12+
* [Working with Git and GitHub](#working-with-git-and-github)
13+
* [General flow](#general-flow)
14+
* [Keeping your fork in sync](#keeping-your-fork-in-sync)
15+
* [Commit messages](#commit-messages)
16+
17+
## General remarks
18+
We are a friendly and welcoming community and look forward to your contributions. Once your contribution is integrated into this repository we feel responsible for it. Therefore, be prepared for constructive feedback. Before we merge anything we need to ensure that it fits in and is consistent with the rest of code.
19+
If you made something really cool but won't spend the time to integrate it into this upstream project please still share it in your fork on GitHub. If you mention it in an issue we'll take a look at it anyway.
20+
21+
## Writing Documentation
22+
ThingPulse maintains documentation for its products at [https://github.com/thingpulse/docs/](https://github.com/thingpulse/docs/). If you contribute features for this project that require altering the respective product guide then we ask you to prepare a pull request with the necessary documentation changes as well.
23+
24+
## Working with Git and GitHub
25+
26+
Avoid intermediate merge commits. [Rebase](https://www.atlassian.com/git/tutorials/merging-vs-rebasing) your feature branch onto `master` to pull updates and verify your local changes against them before placing the pull request.
27+
28+
### General flow
29+
1. [Fork](https://help.github.com/articles/fork-a-repo) this repository on GitHub.
30+
1. [Create a branch](https://help.github.com/articles/creating-and-deleting-branches-within-your-repository/#creating-a-branch) in your fork on GitHub **based on the `master` branch**.
31+
1. Clone the fork on your machine with `git clone https://github.com/<your-account>/<weather-station-fork>.git`
32+
1. `cd <weather-station-fork>` then run `git remote add upstream https://github.com/ThingPulse/esp8266-weather-station`
33+
1. `git checkout <branch-name>`
34+
1. Make changes to the code base and commit them using e.g. `git commit -a -m 'Look ma, I did it'`
35+
1. When you're done:
36+
1. Think about [squashing (some of) your commits](http://www.andrewconnell.com/blog/squash-multiple-git-commits-into-one). There are [several ways](http://stackoverflow.com/a/5201642/131929) to do this. There's no need to squash everything into a single commit as GitHub offers to do this when we merge your changes. However, you might want to trim your commit history to relevant chunks.
37+
1. Bring your fork up-to-date with the upstream repo ([see below](#keeping-your-fork-in-sync)). Then rebase your branch on `master` running `git rebase master`.
38+
1. `git push`
39+
1. [Create a pull request](https://help.github.com/articles/creating-a-pull-request/) (PR) on GitHub.
40+
41+
This is just one way of doing things. If you're proficient in Git matters you're free to choose your own. If you want to read more then the [GitHub chapter in the Git book](http://git-scm.com/book/en/v2/GitHub-Contributing-to-a-Project#The-GitHub-Flow) is a way to start. [GitHub's own documentation](https://help.github.com/categories/collaborating/) contains a wealth of information as well.
42+
43+
### Keeping your fork in sync
44+
You need to sync your fork with the upstream repository from time to time, latest before you rebase (see flow above).
45+
46+
1. `git fetch upstream`
47+
1. `git checkout master`
48+
1. `git merge upstream/master`
49+
50+
### Commit messages
51+
52+
From: [http://git-scm.com/book/ch5-2.html](http://git-scm.com/book/ch5-2.html)
53+
<pre>
54+
Short (50 chars or less) summary of changes
55+
56+
More detailed explanatory text, if necessary. Wrap it to about 72
57+
characters or so. In some contexts, the first line is treated as the
58+
subject of an email and the rest of the text as the body. The blank
59+
line separating the summary from the body is critical (unless you omit
60+
the body entirely); tools like rebase can get confused if you run the
61+
two together.
62+
63+
Further paragraphs come after blank lines.
64+
65+
- Bullet points are okay, too
66+
67+
- Typically a hyphen or asterisk is used for the bullet, preceded by a
68+
single space, with blank lines in between, but conventions vary here
69+
</pre>
70+
71+
Don't forget to [reference affected issues](https://help.github.com/articles/closing-issues-via-commit-messages/) in the commit message to have them closed automatically on GitHub.
72+
73+
[Amend](https://help.github.com/articles/changing-a-commit-message/) your commit messages if necessary to make sure what the world sees on GitHub is as expressive and meaningful as possible.

0 commit comments

Comments
 (0)