Skip to content

Commit 3d1f49a

Browse files
authored
Merge pull request #94 from jordanopensource/docs/contributing-guideline
Create CONTRIBUTING.md
2 parents 03baf27 + 89301f6 commit 3d1f49a

File tree

1 file changed

+61
-0
lines changed

1 file changed

+61
-0
lines changed

CONTRIBUTING.md

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
## Contributing to Contributions Web
2+
3+
Thank you for your interest in contributing to our project! We welcome your help and appreciate your support.
4+
To ensure a smooth and collaborative process, please take a moment to review this contributing guide.
5+
6+
## Code or Documentation Contributions
7+
8+
1. [Fork this repository](https://github.com/jordanopensource/contributions-web/fork).
9+
2. Clone the forked repository to your local machine with this command:
10+
`git clone https://github.com/<your github username>/contributions-web.git`
11+
3. Switch to `development` branch with this command: `git checkout development`.
12+
**If your contribution is a documentation, jump to step 7 below**.
13+
4. (**_You can ignore this step if you're using docker compose_**) Create a `.env` file and copy the content of [`.env.sample`](https://github.com/jordanopensource/contributions-web/blob/development/.env.sample) file into it,
14+
then add the value(s) of environment variable(s).
15+
You can use the current running API URL as the value to `CONTRIBUTIONS_API_URL` variable as the following:
16+
`CONTRIBUTIONS_API_URL=https://contributions.api.prod.josa.ngo/`
17+
18+
5. [Run the project locally](https://github.com/jordanopensource/contributions-web/new/main#running-the-project-locally).
19+
6. Check current [issues](https://github.com/jordanopensource/contributions-web/issues?q=is%3Aopen+is%3Aissue+label%3Ahacktoberfest),
20+
and if you're a beginner, you can [filter issues with `good first issues` label](https://github.com/jordanopensource/contributions-web/issues?q=is%3Aopen+is%3Aissue+label%3Ahacktoberfest+label%3A%22good+first+issue%22).
21+
If you decide to work on one of the issue, write a comment on the issue asking to be assigned to it.
22+
_Do not work on issues that you're not assigned to in order to avoid duplicate work_.
23+
7. Create a new branch from `development` branch for the task that you want to work on:
24+
`git checkout -b <prefix>/branch-title`
25+
- `<prefix>`: The prefix should be one of the following:
26+
- `feat` for new features
27+
- `fix` for bug fixes
28+
- `task` for other general tasks
29+
- `docs` for documentation
30+
- `branch-title` should be short and concise and written in kebab-case (separate each word with '-')
31+
**Example**:
32+
```sh
33+
git checkout development && git pull # pull the latest changes from development branch
34+
35+
git checkout -b fix/type # create new branch
36+
```
37+
38+
8. Write descriptive and concise commit messages
39+
A commit message should describe the changes made in the commit in a clear and concise way. Follow these guidelines when writing commit messages:
40+
- Limit the first line of the commit message to 72 characters or less.
41+
- Use the imperative mood and present tense in the subject line, e.g. "Fix typo in the homepage" instead of "Fixed typo...".
42+
- Use the body of the commit message to provide additional context or details, _if necessary_.
43+
- Use bullet points in the body of the commit message to break down changes, _if necessary_.
44+
45+
9. Push to your branch and then make a pull request from your branch to the base `development`.
46+
47+
### Running the Project Locally
48+
49+
#### Using Docker
50+
Make sure that [docker](https://docs.docker.com/engine/install/) is installed on your system
51+
and then run the project locally using [docker compose](https://github.com/jordanopensource/contributions-web/blob/development/docker-compose.yaml) with this command:
52+
`docker compose up`.
53+
54+
#### Using Node:
55+
1. Make sure [Node](https://nodejs.org/en) v16 is installed. Alternatively, you can use [NVM](https://github.com/nvm-sh/nvm#installing-and-updating) to install any node version.
56+
2. Navigate to the project directory and run `npm i` to install the dependancies.
57+
3. Run the project in development mode by running `npm run dev`.
58+
59+
## Issues and Features Requests
60+
61+
If you want to report a bug or submit a feature request, please use one of the [templates here](https://github.com/jordanopensource/contributions-web/issues/new/choose).

0 commit comments

Comments
 (0)