Follow these instructions to clone the project, create a branch, make changes, and sync your branch with the latest code.
- Node.js (v16 or above)
- Git
-
Clone the repository to your local machine:
git clone <repository-url> cd <project-folder>
-
Install project dependencies:
npm install
Before making any changes, create your own branch:
git checkout -b your-branch-nameExample:
git checkout -b feature/new-feature-
Make your desired changes to the project files.
-
Add the changes to staging:
git add .- Commit your changes:
git commit -m "Your commit message"- Push your branch to the remote repository:
git push origin your-branch-nameTo keep your local branch updated with the latest changes from the main branch:
git checkout maingit pull origin mainAfter pulling the latest changes, switch back to your branch and merge the main branch into it:
git checkout your-branch-namegit merge mainIf there are merge conflicts, resolve them manually and then commit the resolved files:
git add .
git commit -m "Resolved merge conflicts"Once everything is merged and conflicts are resolved, push the changes to your branch:
git push origin your-branch-name