Skip to content

Commit 76063e2

Browse files
Merge pull request #141 from tcet-opensource/95-create_Contribution.md
create contribution.md
2 parents b5d0a35 + 124073d commit 76063e2

File tree

1 file changed

+99
-0
lines changed

1 file changed

+99
-0
lines changed

Contribution.md

Lines changed: 99 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,99 @@
1+
# Welcome to TCET Open Source contributing guide
2+
3+
Thank you for investing your time in contributing to our project!
4+
5+
In this guide you will get an overview of the contribution workflow from opening an issue, creating a PR, and merging the PR.
6+
7+
8+
## New contributor guide
9+
10+
To get an overview and installation of the project, read the [README](README.md). Here are some resources to help you get started with open source contributions:
11+
12+
- [Finding ways to contribute to open source on GitHub](https://docs.github.com/en/get-started/exploring-projects-on-github/finding-ways-to-contribute-to-open-source-on-github)
13+
- [Set up Git](https://docs.github.com/en/get-started/quickstart/set-up-git)
14+
- [GitHub flow](https://docs.github.com/en/get-started/quickstart/github-flow)
15+
- [Collaborating with pull requests](https://docs.github.com/en/github/collaborating-with-pull-requests)
16+
17+
18+
## Getting started
19+
20+
To navigate our codebase with confidence, see our [Github Repository](https://github.com/tcet-opensource/erp-backend)
21+
22+
## Issues
23+
24+
25+
#### Asking to work on an issue
26+
27+
Scan through our [existing issues](https://github.com/tcet-opensource/erp-backend/issues) to find one that interests you. You can narrow down the search using `labels` as filters. See [Labels](https://github.com/tcet-opensource/erp-backend/labels) for more information. For contributing comment on that specific issue that you want to work on it and we will assign that specific issue to you. Please remember only start working on the issue after it is assigned to you.
28+
29+
#### Create a new issue
30+
31+
If you find a bug or want to add any sort of feature in the repository , [search if an issue already exists](https://github.com/tcet-opensource/erp-backend/issues). If a related issue doesn't exist, you can open a new issue using a relevant [issue form](https://github.com/tcet-opensource/erp-backend/issues/new). Please note that the name of the issue title should be relevant and should give an idea about what you are working on.
32+
33+
34+
## Make Changes
35+
36+
### Make changes in the UI
37+
38+
Click **Make a contribution** at the bottom of erp-backend to make small changes such as a typo, sentence fix, or a broken link. This takes you to the `.md` file where you can make your changes and [create a pull request](#pull-request) for a review.
39+
40+
41+
### Make changes locally
42+
43+
1. External Contributors , Fork the repository
44+
- Using GitHub Desktop:
45+
- [Getting started with GitHub Desktop](https://docs.github.com/en/desktop/installing-and-configuring-github-desktop/getting-started-with-github-desktop) will guide you through setting up Desktop.
46+
- Once Desktop is set up, you can use it to fork the repo
47+
- Using the command line:
48+
- [Fork the repo](https://github.com/tcet-opensource/erp-backend/fork), so that you can make your changes without affecting the original project until you're ready to merge them.
49+
- After forking clone the forked repository
50+
- Switch from main branch to development branch in your cloned repository
51+
- To switch to development write command `git remote add upstream <link of original repo>` and `git fetch upstream` in the terminal
52+
- To install node modules use command `npm ci`
53+
- Switch to Development Branch and create a working branch for each issue.
54+
- To create a branch use command `git branch <name of the branch>`
55+
- NOTE: The name of the branch should in the format of -> Issue number-name of the issue (eg: 50-create_CRUD_for_infra_model)
56+
- Then from the development branch move to the branch created by using command `git checkout <branch name>`
57+
- All changes on the code should be done on your specific branch
58+
- Test your changes: After making your changes, it is crucial to thoroughly test them to ensure they function as intended and do not introduce any new bugs. Run any relevant tests or simulations and verify that the modified code performs correctly.
59+
- Before pushing the changes sync fork in the forked repo and pull the changes before pushing
60+
- After pushing go to the forked repository and press contribute and make a pull request
61+
62+
2. Internal Contributors, Clone the Repository
63+
&nbsp;
64+
`git clone -b development https://github.com/tcet-opensource/erp-backend.git`
65+
- To install node modules use command `npm ci`
66+
- Switch to Development Branch and create a working branch for each issue.
67+
- To create a branch use command `git branch <name of the branch>`
68+
- NOTE: The name of the branch should in the format of -> Issue number-name of the issue (eg: 50-create_CRUD_for_infra_model)
69+
- Then from the development branch move to the branch created by using command `git checkout <branch name>`
70+
- All changes on the code should be done on your specific branch
71+
- Test your changes: After making your changes, it is crucial to thoroughly test them to ensure they function as intended and do not introduce any new bugs. Run any relevant tests or simulations and verify that the modified code performs correctly.
72+
73+
74+
### Commit your changes
75+
- Stage your changes: Use the git add command to stage the modified files for the commit. This marks the changes as ready to be included in the next commit.
76+
`git add <file1> <file2> ...` or `git add .`
77+
- Commit your changes: Create a commit to record your modifications with a meaningful commit message. This helps in tracking and understanding the purpose of the changes.
78+
`git commit -m "relevant info of the change"`
79+
- Before pushing the changes on the repository always remember to pull the code to avoid any merge conflicts
80+
`git pull origin development`
81+
- try pushing the code on the development branch and not directly to the main branch
82+
83+
### Push your Changes
84+
- After committing your changes, you push them to a remote repository (in this case, your forked repository on GitHub) using the git push command. Pushing your changes uploads them to the remote repository, making them visible to others and allowing you to share your work.
85+
`git push origin <branch name>`
86+
87+
88+
### Pull Request
89+
90+
When you're finished with the changes, create a pull request, also known as a PR.
91+
- Don't forget to link PR to issue by using "#" issue number , if you are solving one.
92+
- Once you submit your PR, a team member will review your proposal. We may ask questions or request additional information.
93+
- We may ask for changes to be made before a PR can be merged, either using suggested changes or pull request comments. You can apply suggested changes directly through the UI. You can make any other changes in your fork, then commit them to your branch.
94+
- As you update your PR and apply changes, mark each conversation as resolved
95+
- If you run into any merge issues, checkout this [git merge conflicts](https://github.com/skills/resolve-merge-conflicts) to help you resolve merge conflicts and other issues.
96+
97+
### Your PR is merged!
98+
99+
Congratulations , The TCET Open Source team thanks you.

0 commit comments

Comments
 (0)