Skip to content

Commit 1f367c5

Browse files
committed
Merge pull request #39 from maclover7/contributing
Add CONTRIBUTING.md
2 parents b88d0b3 + 51292a2 commit 1f367c5

File tree

3 files changed

+109
-8
lines changed

3 files changed

+109
-8
lines changed

CONTRIBUTING.md

Lines changed: 99 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,99 @@
1+
Contributing to Rails::Dom::Testing
2+
=====================
3+
4+
[![Build Status](https://travis-ci.org/rails/rails-dom-testing.svg?branch=master)](https://travis-ci.org/rails/rails-dom-testing)
5+
6+
Rails::Dom::Testing is work of [many contributors](https://github.com/rails/rails-dom-testing/graphs/contributors). You're encouraged to submit [pull requests](https://github.com/rails/rails-dom-testing/pulls), [propose features and discuss issues](https://github.com/rails/rails-dom-testing/issues).
7+
8+
#### Fork the Project
9+
10+
Fork the [project on Github](https://github.com/rails/rails-dom-testing) and check out your copy.
11+
12+
```
13+
git clone https://github.com/contributor/rails-dom-testing.git
14+
cd rails-dom-testing
15+
git remote add upstream https://github.com/rails/rails-dom-testing.git
16+
```
17+
18+
#### Create a Topic Branch
19+
20+
Make sure your fork is up-to-date and create a topic branch for your feature or bug fix.
21+
22+
```
23+
git checkout master
24+
git pull upstream master
25+
git checkout -b my-feature-branch
26+
```
27+
28+
#### Bundle Install and Test
29+
30+
Ensure that you can build the project and run tests.
31+
32+
```
33+
bundle install
34+
bundle exec rake test
35+
```
36+
37+
#### Write Tests
38+
39+
Try to write a test that reproduces the problem you're trying to fix or describes a feature that you want to build. Add to [test](test).
40+
41+
We definitely appreciate pull requests that highlight or reproduce a problem, even without a fix.
42+
43+
#### Write Code
44+
45+
Implement your feature or bug fix.
46+
47+
Make sure that `bundle exec rake test` completes without errors.
48+
49+
#### Write Documentation
50+
51+
Document any external behavior in the [README](README.md).
52+
53+
#### Commit Changes
54+
55+
Make sure git knows your name and email address:
56+
57+
```
58+
git config --global user.name "Your Name"
59+
git config --global user.email "[email protected]"
60+
```
61+
62+
Writing good commit logs is important. A commit log should describe what changed and why.
63+
64+
```
65+
git add ...
66+
git commit
67+
```
68+
69+
#### Push
70+
71+
```
72+
git push origin my-feature-branch
73+
```
74+
75+
#### Make a Pull Request
76+
77+
Go to https://github.com/contributor/rails-dom-testing and select your feature branch. Click the 'Pull Request' button and fill out the form. Pull requests are usually reviewed within a few days.
78+
79+
#### Rebase
80+
81+
If you've been working on a change for a while, rebase with upstream/master.
82+
83+
```
84+
git fetch upstream
85+
git rebase upstream/master
86+
git push origin my-feature-branch -f
87+
```
88+
89+
#### Check on Your Pull Request
90+
91+
Go back to your pull request after a few minutes and see whether it passed muster with Travis-CI. Everything should look green, otherwise fix issues and amend your commit as described above.
92+
93+
#### Be Patient
94+
95+
It's likely that your change will not be merged and that the nitpicky maintainers will ask you to do more, or fix seemingly benign problems. Hang on there!
96+
97+
#### Thank You
98+
99+
Please do know that we really appreciate and value your time and work. We love you, really.

LICENSE.txt renamed to MIT-LICENSE

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Copyright (c) 2013 Kasper Timm Hansen
1+
Copyright (c) 2013-2015 Kasper Timm Hansen
22

33
MIT License
44

@@ -20,3 +20,4 @@ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
2020
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
2121
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
2222
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
23+

README.md

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
# Rails::Dom::Testing
2-
[![Build Status](https://travis-ci.org/rails/rails-dom-testing.svg)](https://travis-ci.org/rails/rails-dom-testing)
32

43
This gem is responsible for comparing HTML doms and asserting that DOM elements are present in Rails applications.
54
Doms are compared via `assert_dom_equal` and `assert_dom_not_equal`.
@@ -67,10 +66,12 @@ Under the hood the doms are parsed with Nokogiri and you'll generally be working
6766
Read more about Nokogiri:
6867
- [Nokogiri](http://nokogiri.org)
6968

70-
## Contributing
69+
## Contributing to Rails::Dom::Testing
7170

72-
1. Fork it
73-
2. Create your feature branch (`git checkout -b my-new-feature`)
74-
3. Commit your changes (`git commit -am 'Add some feature'`)
75-
4. Push to the branch (`git push origin my-new-feature`)
76-
5. Create new Pull Request
71+
Rails::Dom::Testing is work of many contributors. You're encouraged to submit pull requests, propose
72+
features and discuss issues.
73+
74+
See [CONTRIBUTING](CONTRIBUTING.md).
75+
76+
## License
77+
Rails::Dom::Testing is released under the [MIT License](MIT-LICENSE).

0 commit comments

Comments
 (0)