Skip to content

Commit 6253b8c

Browse files
committed
chore(docs): add Contributing guidelines
1 parent 71698d5 commit 6253b8c

File tree

1 file changed

+101
-0
lines changed

1 file changed

+101
-0
lines changed

CONTRIBUTING.md

Lines changed: 101 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,101 @@
1+
# Contributing Guidelines
2+
3+
When contributing to this repository, please first discuss the change you wish to make via issue with the maintainers of this repository before making a change.
4+
5+
Please note we have a code of conduct, please follow it in all your interactions with the project.
6+
7+
## Pull Request Process
8+
9+
1. Ensure any install or build dependencies are removed before the end of the layer when doing a
10+
build. Add only relevant files to commit and ignore the rest to keep the repo clean.
11+
2. Update the README.md or other documentation with details of changes to the interface, this includes new environment
12+
variables, exposed ports, useful file locations and container parameters.
13+
3. You should request review from the maintainers once you submit the Pull Request.
14+
15+
## Git Workflow
16+
17+
### **Step 1:** Fork the repository
18+
19+
### **Step 2:** Git Setup & Download
20+
21+
```bash
22+
# Clone the repo
23+
$ git clone [email protected]:<User-Name>/prettier-cli-action.git
24+
25+
# Add upstream remote
26+
$ git remote add upstream [email protected]:Monday-Morning/project-reclamation.git
27+
28+
# Fetch and rebase with upstream/main
29+
$ git fetch upstream
30+
$ git pull --ff upstream/main
31+
32+
# Push if any changes are rebased
33+
$ git push origin main
34+
```
35+
36+
### **Step 3:** Create and Publish Working Branch
37+
38+
```bash
39+
# Ensure you are in the main branch
40+
$ git branch
41+
42+
# Create your new branch
43+
$ git checkout -b <type>/<issue|issue-number>/{<additional-fixes>}
44+
$ git push origin <type>/<issue|issue-number>/{<additional-fixes>}
45+
46+
## Types:
47+
# wip - Work in Progress; long term work; mainstream changes;
48+
# feat - New Feature; future planned; non-mainstream changes;
49+
# bug - Bug Fixes
50+
# junk - Experimental; random experiemntal features; throwaway branch;
51+
```
52+
53+
### On Task Completion, **Step 4:** Commit and push your work
54+
55+
```bash
56+
# Ensure branch
57+
$ git branch
58+
59+
# Fetch and rebase with upstream/main
60+
$ git fetch upstream
61+
$ git pull --ff upstream/main
62+
63+
# Add untracked files one by one
64+
$ git add .
65+
66+
# Commit all changes with appropriate commit message and description. Strcitly follow commit message standards.
67+
$ git commit -m "your-commit-message" -m "your-commit-description"
68+
69+
# Fetch and rebase with upstream/main again
70+
$ git fetch upstream
71+
$ git pull --ff upstream/main
72+
73+
# Push changes to your forked repository
74+
$ git push origin <type>/<issue|issue-number>/{<additional-fixes>}
75+
```
76+
77+
### **Step 5:** Create the PR using GitHub Website
78+
79+
1. Create Pull Request from <type>/<issue|issue-number>/{<additional-fixes>} branch in your forked repository to the main branch in the upstream repository. Again, ensure the name follows commit standards and the description must detail the work done.
80+
1. Link Pull Request to the appropriate Issue using closing keywords.
81+
82+
### **After PR Merge, Step 6:** Working repository cleanup
83+
84+
```bash
85+
# Fetch and push changes
86+
$ git checkout main
87+
$ git fetch upstream main
88+
$ git pull --ff upstream main
89+
$ git push origin main
90+
91+
# Delete branch from forked repo
92+
$ git branch -d <type>/<issue|issue-number>/{<additional-fixes>}
93+
$ git push --delete origin <type>/<issue|issue-number>/{<additional-fixes>}
94+
```
95+
96+
---
97+
98+
## Important Instuctions & Guides
99+
100+
- Always follow [conventional commits standards](https://www.conventionalcommits.org/en/v1.0.0/)
101+
- About the [fork-and-branch workflow](https://blog.scottlowe.org/2015/01/27/using-fork-branch-git-workflow/)

0 commit comments

Comments
 (0)