This guide details the general rules to follow when working. Each project may have its own variation of this contribution guide.
NOTE: Never push code directly to the organization repo
-
Install git
-
Fork the project repo
-
Clone your fork on your local computer
git clone https://github.com/<your-username>/<repository-name>.git
- Change working directory
cd <repository-name>
- Add the upstream repository
git remote add upstream https://github.com/VIZZ-WEB-SOLUTIONS/<repository-name>.git
-
Now
git remote -v
should show 2 repositories.origin
Your forked repositoryupstream
Vizz Web Solutions Dev repository
-
install dependencies
- Pull the latest changes
git fetch --all
git pull --rebase upstream main
- Create a branch for the changes you want to work on rather than working off of your local main branch:
// new branch name should relate to the features you are working on
git checkout -b <new-branch-name> upstream/main
- Write some code!
-
git push -u origin
<new-branch-name>
-
In order to make the team aware of your changes, you can make a PR to the
VIZZ-WEB-SOLUTIONS/<repository_name>
repository from your fork. -
Ask other team members to review the code.
-
Resolve all merge conflicts.