Skip to content

Commit 152c4a5

Browse files
authored
Merge pull request #42 from nitingupta95/docs/add-contributing-guide
docs: added the contributing-guide
2 parents 284b7b5 + b0e801d commit 152c4a5

File tree

1 file changed

+125
-18
lines changed

1 file changed

+125
-18
lines changed
Lines changed: 125 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,142 @@
1-
# Contribute to <Project_Name>
1+
# Contributing to RBAC
22

3-
Thank you for taking the time to contribute to <project_name>! We really appreciate it.
3+
Thank you for taking the time to contribute to **RBAC**! 🎉
4+
We appreciate your interest and contributions — whether it's fixing bugs, improving documentation, or adding new features.
45

5-
Before contributing, please make sure to read the [Code of Conduct](../../CODE_OF_CONDUCT.md). We expect you to follow it in all your interactions with the project.
6+
Before contributing, please make sure to read our [Code of Conduct](../../CODE_OF_CONDUCT.md).
7+
We expect all contributors to uphold it in all interactions related to this project.
68

7-
## New to <Project_Name>?
9+
---
810

9-
If you are new to <Project_Name>, please take a look at the [documentation](./Project_Tour.md). It is a great place to start.
11+
## 🧭 New to RBAC?
1012

11-
## New Contributor Guide
13+
If you’re new here, start by exploring our [Project Tour](./Project_Tour.md) for an overview of the architecture, setup, and modules.
14+
To understand the code structure, check out the [README.md](../src/README.md) file inside the `src` directory.
1215

13-
To get an overview of the codebase, check out the '[README.md](../src/README.md)' file in the `src` directory.
16+
---
1417

15-
that will help you understand the structure of the project.
18+
## 💡 Ways to Contribute
1619

17-
## How to Contribute
20+
There are many ways you can help make RBAC better!
1821

19-
### Reporting Bugs
22+
### 🐞 Reporting Bugs
23+
If you find a bug or an unexpected behavior:
24+
1. Check existing [Issues](../../issues) to see if it’s already reported.
25+
2. If not, [submit a new bug report](../ISSUE_TEMPLATE/bug_report.yaml).
26+
3. Include clear steps to reproduce, expected vs actual behavior, and screenshots if relevant.
2027

21-
If you find a bug in the source code, you can help us by [submitting an issue](../ISSUE_TEMPLATE/bug_report.yaml).
28+
---
2229

23-
### Suggesting Enhancements
30+
### 🚀 Suggesting Enhancements
31+
Have an idea to improve RBAC? We’d love to hear it!
32+
- Submit a [Feature Request](../ISSUE_TEMPLATE/feature_request.yaml).
33+
- Describe the motivation, proposed solution, and any possible alternatives.
2434

25-
If you want to suggest an enhancement to <Project_Name>, please [submit an issue](../ISSUE_TEMPLATE/feature_request.yaml).
35+
---
2636

27-
### Pull Requests
37+
### 🧑‍💻 Submitting a Pull Request (PR)
2838

29-
If you want to contribute to <Project_Name>, submit a pull request.
39+
We welcome pull requests for fixes, features, and docs improvements.
3040

31-
- url: `https://github.com/OPCODE-Open-Spring-Fest/<project_Name>/compare/branch...YOURGITHUBUSERNAME:<project_Name>:BRANCH?quick_pull=1&template=pr.md`
41+
#### 🔄 Fork & Clone
42+
1. Fork the repository:
43+
```bash
44+
git clone https://github.com/YOUR_GITHUB_USERNAME/RBAC.git
45+
cd RBAC
46+
```
47+
2. Create a new branch for your feature or fix:
48+
```bash
49+
git checkout -b feature/your-feature-name
50+
```
3251

33-
### Requirements
52+
#### 🧩 Make Your Changes
53+
- Follow existing code style and conventions.
54+
- Add comments and documentation where needed.
55+
- Test your changes before committing.
3456

35-
### Setup
57+
#### 🧾 Commit Your Changes
58+
Use **conventional commit messages** (for example):
59+
```
60+
fix: resolve login redirect bug
61+
docs: update API setup instructions
62+
feat: add JWT-based role validation middleware
63+
```
64+
65+
#### 📬 Push and Create a PR
66+
Push your branch and open a pull request using the following URL:
67+
```
68+
https://github.com/OPCODE-Open-Spring-Fest/RBAC/compare/main...YOUR_GITHUB_USERNAME:RBAC:BRANCH?quick_pull=1&template=pr.md
69+
```
70+
71+
Your PR should:
72+
- Clearly describe the changes.
73+
- Reference related issues (e.g., “Closes #23”).
74+
- Include screenshots or logs if relevant.
75+
76+
---
77+
78+
## ⚙️ Local Setup
79+
80+
To set up the project locally:
81+
82+
```bash
83+
git clone https://github.com/OPCODE-Open-Spring-Fest/RBAC.git
84+
cd RBAC
85+
npm install
86+
npm run dev
87+
```
88+
89+
> 💡 Ensure Node.js and npm are installed before running the project.
90+
91+
---
92+
93+
## ✅ Code Guidelines
94+
95+
- Follow **ESLint** rules configured in the project.
96+
- Write meaningful commit messages and pull request titles.
97+
- Keep PRs focused — one purpose per PR.
98+
- Update or add relevant documentation when changing code.
99+
100+
---
101+
102+
## 🧪 Testing
103+
104+
Run the test suite before submitting your PR:
105+
106+
```bash
107+
npm test
108+
```
109+
110+
If you add new functionality, include corresponding unit tests.
111+
112+
---
113+
114+
## 🧱 Branch Naming Convention
115+
116+
Please follow this format for branch names:
117+
- `feat/<feature-name>` – for new features
118+
- `fix/<bug-name>` – for bug fixes
119+
- `docs/<file-update>` – for documentation
120+
- `refactor/<component>` – for refactoring
121+
122+
Example:
123+
```
124+
feat/add-role-based-access
125+
fix/login-redirect-error
126+
docs/update-readme
127+
```
128+
129+
---
130+
131+
## 🙌 Need Help?
132+
133+
If you’re stuck or need clarification:
134+
- Open a **discussion** in the [GitHub Discussions](../../discussions) tab.
135+
- Or ask in the issue thread related to your contribution.
136+
137+
---
138+
139+
## 💬 Attribution
140+
141+
This project follows open-source best practices.
142+
Inspired by contributing guides from [Contributor Covenant](https://www.contributor-covenant.org/) and [GitHub Docs](https://docs.github.com/en/get-started/quickstart/contributing-to-projects).

0 commit comments

Comments
 (0)