You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+47-55Lines changed: 47 additions & 55 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,14 +1,28 @@
1
-
Hello! Thank you for choosing to help contribute to the java-http-client project. There are many ways you can contribute and help is always welcome.
2
-
1
+
Hello! Thank you for choosing to help contribute to one of the SendGrid open source projects. There are many ways you can contribute and help is always welcome. We simply ask that you follow the following contribution policies.
2
+
3
+
-[CLAs and CCLAs](#cla)
4
+
-[Roadmap & Milestones](#roadmap)
5
+
-[Feature Request](#feature_request)
6
+
-[Submit a Bug Report](#submit_a_bug_report)
7
+
-[Improvements to the Codebase](#improvements_to_the_codebase)
8
+
-[Understanding the Code Base](#understanding_the_codebase)
-[Creating a Pull Request](#creating_a_pull_request)
12
+
13
+
<aname="roadmap"></a>
3
14
We use [Milestones](https://github.com/sendgrid/java-http-client/milestones) to help define current roadmaps, please feel free to grab an issue from the current milestone. Please indicate that you have begun work on it to avoid collisions. Once a PR is made, community review, comments, suggestions and additional PRs are welcomed and encouraged.
4
15
5
-
*[Feature Request](#feature_request)
6
-
*[Submit a Bug Report](#submit_a_bug_report)
7
-
*[Improvements to the Codebase](#improvements_to_the_codebase)
8
-
*[Understanding the Code Base](#understanding_the_codebase)
*[Creating a Pull Request](#creating_a_pull_request)
16
+
<aname="cla"></a>
17
+
## CLAs and CCLAs
18
+
19
+
Before you get started, SendGrid requires that a SendGrid Contributor License Agreement (CLA) or a SendGrid Company Contributor Licensing Agreement (CCLA) be filled out by every contributor to a SendGrid open source project.
20
+
21
+
Our goal with the CLA and CCLA is to clarify the rights of our contributors and reduce other risks arising from inappropriate contributions. The CLA also clarifies the rights SendGrid holds in each contribution and helps to avoid misunderstandings over what rights each contributor is required to grant to SendGrid when making a contribution. In this way the CLA and CCLA encourage broad participation by our open source community and help us build strong open source projects, free from any individual contributor withholding or revoking rights to any contribution.
22
+
23
+
SendGrid does not merge a pull request made against a SendGrid open source project until that pull request is associated with a signed CLA (or CCLA). Copies of the CLA and CCLA are available [here](https://drive.google.com/a/sendgrid.com/file/d/0B0PlcM9qA91LN2VEUTJWU2RIVXc/view).
24
+
25
+
You may submit your completed [CLA or CCLA](https://drive.google.com/a/sendgrid.com/file/d/0B0PlcM9qA91LN2VEUTJWU2RIVXc/view) to SendGrid at [[email protected]](mailto:[email protected]). SendGrid will then confirm you are ready to begin making contributions.
12
26
13
27
There are a few ways to contribute, which we'll enumerate below:
14
28
@@ -37,47 +51,25 @@ Before you decide to create a new issue, please try the following:
37
51
38
52
### Please use our Bug Report Template
39
53
40
-
In order to make the process easier, we've included a sample bug report template (borrowed from [Ghost](https://github.com/TryGhost/Ghost/)). The template uses [GitHub flavored markdown](https://help.github.com/articles/github-flavored-markdown/) for formatting.
41
-
42
-
```
43
-
Short and descriptive example bug report title
44
-
45
-
#### Issue Summary
46
-
47
-
A summary of the issue and the environment in which it occurs. If suitable, include the steps required to reproduce the bug. Please feel free to include screenshots, screencasts, code examples.
48
-
49
-
50
-
#### Steps to Reproduce
51
-
52
-
1. This is the first step
53
-
2. This is the second step
54
-
3. Further steps, etc.
55
-
56
-
Any other information you want to share that is relevant to the issue being reported. Especially, why do you consider this to be a bug? What do you expect to happen instead?
In order to make the process easier, we've included a [sample bug report template](https://github.com/sendgrid/java-http-client/.github/ISSUE_TEMPLATE) (borrowed from [Ghost](https://github.com/TryGhost/Ghost/)). The template uses [GitHub flavored markdown](https://help.github.com/articles/github-flavored-markdown/) for formatting.
63
55
64
56
<aname="improvements_to_the_codebase"></a>
65
57
## Improvements to the Codebase
66
58
67
-
We welcome direct contributions to the rest code base. Thank you!
59
+
We welcome direct contributions to the java-http-client code base. Thank you!
68
60
69
61
### Development Environment ###
70
62
71
-
#### Install and run locally ####
63
+
#### Install and Run Locally ####
72
64
73
65
##### Prerequisites #####
74
66
75
-
* Java 1.7 and up
76
-
* Please see [pom.xml](https://github.com/sendgrid/java-http-client/blob/master/pom.xml)
67
+
- Java 1.7 and up
68
+
- Please see [build.gradle](https://github.com/sendgrid/java-http-client/blob/master/build.gradle)
Working examples that demonstrate usage. To run the example code:
104
-
105
89
```bash
106
90
mvn package
107
91
cd ../examples
108
92
javac -classpath ./commons-logging-1.2.jar:./httpcore-4.4.4.jar:./httpclient-4.5.2.jar:./jackson-databind-2.7.3.jar:./jackson-annotations-2.7.0.jar:./jackson-core-2.7.3.jar:../target/http-1.0-SNAPSHOT.jar:. Example.java && java -classpath ./commons-logging-1.2.jar:./httpcore-4.4.4.jar:./httpclient-4.5.2.jar:./jackson-databind-2.7.3.jar:./jackson-annotations-2.7.0.jar:./jackson-core-2.7.3.jar:../target/http-1.0-SNAPSHOT.jar:. Example
109
93
```
110
94
95
+
<aname="understanding_the_codebase"></a>
96
+
## Understanding the Code Base
97
+
98
+
<!---optionally provide a brief summary explaning the architecture of the code--->
99
+
100
+
**/examples**
101
+
102
+
Working examples that demonstrate usage.
103
+
111
104
**Client.java**
112
105
113
106
The main function that does the heavy lifting (and external entry point) is `api`.
@@ -129,11 +122,12 @@ Provides a standard interface to an API's response.
129
122
130
123
All PRs require passing tests before the PR will be reviewed.
131
124
132
-
All test files are in `[http/src/test/java/com/sendgrid](https://github.com/sendgrid/java-http-client/blob/master/src/test/java/com/sendgrid/ClientTest.java)`.
125
+
All test files are in [`http/src/test/java/com/sendgrid`](https://github.com/sendgrid/java-http-client/blob/master/src/test/java/com/sendgrid/ClientTest.java).
133
126
134
127
For the purposes of contributing to this repo, please update the [`ClientTest.java`](https://github.com/sendgrid/java-http-client/blob/master/src/test/java/com/sendgrid/ClientTest.java) file with unit tests as you modify the code.
135
128
136
-
Run the test:
129
+
130
+
Run the tests:
137
131
138
132
```java
139
133
./gradlew test -i
@@ -144,13 +138,11 @@ Run the test:
144
138
145
139
Generally, we follow the style guidelines as suggested by the official language. However, we ask that you conform to the styles that already exist in the library. If you wish to deviate, please explain your reasoning.
146
140
147
-
Please run your code through[FindBugs](http://findbugs.sourceforge.net/) and [CheckStyle](http://checkstyle.sourceforge.net/) with [Google's Java Style Guide](http://checkstyle.sourceforge.net/reports/google-java-style.html).
141
+
Please run your code through:
148
142
149
-
### Directory Structure
143
+
-[FindBugs](http://findbugs.sourceforge.net/)
144
+
-[CheckStyle](http://checkstyle.sourceforge.net/) with [Google's Java Style Guide](http://checkstyle.sourceforge.net/reports/google-java-style.html).
150
145
151
-
*`examples/` for example calls
152
-
*`src/main/java/com/sendgrid` for the main source code
153
-
*`src/test/java/com/sendgrid` for the unit tests
154
146
155
147
## Creating a Pull Request<aname="creating_a_pull_request"></a>
156
148
@@ -161,7 +153,7 @@ Please run your code through [FindBugs](http://findbugs.sourceforge.net/) and [C
161
153
# Clone your fork of the repo into the current directory
Hello! Thank you for choosing to help contribute to the java-http-client project. There are many ways you can contribute and help is always welcome.
2
+
3
+
We use [Milestones](https://github.com/sendgrid/java-http-client/milestones) to help define current roadmaps, please feel free to grab an issue from the current milestone. Please indicate that you have begun work on it to avoid collisions. Once a PR is made, community review, comments, suggestions and additional PRs are welcomed and encouraged.
4
+
5
+
*[Feature Request](#feature_request)
6
+
*[Submit a Bug Report](#submit_a_bug_report)
7
+
*[Improvements to the Codebase](#improvements_to_the_codebase)
8
+
*[Understanding the Code Base](#understanding_the_codebase)
*[Creating a Pull Request](#creating_a_pull_request)
12
+
13
+
There are a few ways to contribute, which we'll enumerate below:
14
+
15
+
<aname="feature_request"></a>
16
+
## Feature Request
17
+
18
+
If you'd like to make a feature request, please read this section.
19
+
20
+
The GitHub issue tracker is the preferred channel for library feature requests, but please respect the following restrictions:
21
+
22
+
- Please **search for existing issues** in order to ensure we don't have duplicate bugs/feature requests.
23
+
- Please be respectful and considerate of others when commenting on issues
24
+
25
+
<aname="submit_a_bug_report"></a>
26
+
## Submit a Bug Report
27
+
28
+
Note: DO NOT include your credentials in ANY code examples, descriptions, or media you make public.
29
+
30
+
A software bug is a demonstrable issue in the code base. In order for us to diagnose the issue and respond as quickly as possible, please add as much detail as possible into your bug report.
31
+
32
+
Before you decide to create a new issue, please try the following:
33
+
34
+
1. Check the Github issues tab if the identified issue has already been reported, if so, please add a +1 to the existing post.
35
+
2. Update to the latest version of this code and check if issue has already been fixed
36
+
3. Copy and fill in the Bug Report Template we have provided below
37
+
38
+
### Please use our Bug Report Template
39
+
40
+
In order to make the process easier, we've included a sample bug report template (borrowed from [Ghost](https://github.com/TryGhost/Ghost/)). The template uses [GitHub flavored markdown](https://help.github.com/articles/github-flavored-markdown/) for formatting.
41
+
42
+
```
43
+
Short and descriptive example bug report title
44
+
45
+
#### Issue Summary
46
+
47
+
A summary of the issue and the environment in which it occurs. If suitable, include the steps required to reproduce the bug. Please feel free to include screenshots, screencasts, code examples.
48
+
49
+
50
+
#### Steps to Reproduce
51
+
52
+
1. This is the first step
53
+
2. This is the second step
54
+
3. Further steps, etc.
55
+
56
+
Any other information you want to share that is relevant to the issue being reported. Especially, why do you consider this to be a bug? What do you expect to happen instead?
Working examples that demonstrate usage. To run the example code:
104
+
105
+
```bash
106
+
mvn package
107
+
cd ../examples
108
+
javac -classpath ./commons-logging-1.2.jar:./httpcore-4.4.4.jar:./httpclient-4.5.2.jar:./jackson-databind-2.7.3.jar:./jackson-annotations-2.7.0.jar:./jackson-core-2.7.3.jar:../target/http-1.0-SNAPSHOT.jar:. Example.java && java -classpath ./commons-logging-1.2.jar:./httpcore-4.4.4.jar:./httpclient-4.5.2.jar:./jackson-databind-2.7.3.jar:./jackson-annotations-2.7.0.jar:./jackson-core-2.7.3.jar:../target/http-1.0-SNAPSHOT.jar:. Example
109
+
```
110
+
111
+
**Client.java**
112
+
113
+
The main function that does the heavy lifting (and external entry point) is `api`.
114
+
115
+
**Method.java**
116
+
117
+
These are the supported Methods.
118
+
119
+
**Request.java**
120
+
121
+
Provides a standard interface to an API's HTTP request.
122
+
123
+
**Response.java**
124
+
125
+
Provides a standard interface to an API's response.
126
+
127
+
<aname="testing"></a>
128
+
## Testing
129
+
130
+
All PRs require passing tests before the PR will be reviewed.
131
+
132
+
All test files are in `[http/src/test/java/com/sendgrid](https://github.com/sendgrid/java-http-client/blob/master/src/test/java/com/sendgrid/ClientTest.java)`.
133
+
134
+
For the purposes of contributing to this repo, please update the [`ClientTest.java`](https://github.com/sendgrid/java-http-client/blob/master/src/test/java/com/sendgrid/ClientTest.java) file with unit tests as you modify the code.
Generally, we follow the style guidelines as suggested by the official language. However, we ask that you conform to the styles that already exist in the library. If you wish to deviate, please explain your reasoning.
146
+
147
+
Please run your code through [FindBugs](http://findbugs.sourceforge.net/) and [CheckStyle](http://checkstyle.sourceforge.net/) with [Google's Java Style Guide](http://checkstyle.sourceforge.net/reports/google-java-style.html).
148
+
149
+
### Directory Structure
150
+
151
+
*`examples/` for example calls
152
+
*`src/main/java/com/sendgrid` for the main source code
153
+
*`src/test/java/com/sendgrid` for the unit tests
154
+
155
+
## Creating a Pull Request<aname="creating_a_pull_request"></a>
156
+
157
+
1.[Fork](https://help.github.com/fork-a-repo/) the project, clone your fork,
158
+
and configure the remotes:
159
+
160
+
```bash
161
+
# Clone your fork of the repo into the current directory
0 commit comments