- Git Tutorial (w3schools.com)
- How to Use Git and GitHub – Introduction for Beginners (freecodecamp.org)
- Learn Git Branching (Interactive tutorial)
- Git - Basic Branching and Merging (git-scm.com)
- Pull Requests in VS Code - YouTube
Description: You will create a simple static website with a few pages and use Git and GitHub to manage the project's version control. Tasks: 1. Setup:
- Set up Git on your local machine if you haven't already.
- Create a GitHub account if you don't have one.
- Fork this repository and clone it to your local machine.
2. Initial Commit:
- Go to the folder where you cloned the repository.
- Inside the folder, create an HTML file (e.g., index.html) and add some basic content.
- Add the HTML file to the repository using
git add
. - Commit the changes using
git commit
.
3. Branching:
- Create a new branch named "feature" using
git branch feature
. - Switch to the "feature" branch using
git checkout feature
. - Make some changes to the HTML file in the "feature" branch, like adding a new page or modifying existing content.
4. Merging:
- Switch back to the main branch using
git checkout main
. - Merge the changes from the "feature" branch into the main branch using
git merge feature
.
5. Pull Requests:
- Go to the GitHub repository.
- Create a new Pull Request (PR) to merge the "feature" branch into the main branch.
- Add a description for the PR.
- Review the changes and create the PR.
6. Collaboration (Optional):
- Invite a friend to collaborate on the project by adding them as a collaborator on the GitHub repository.
- Have your friend clone the repository, create a branch, make changes, and create a Pull Request as well.
- Review and merge their changes into the main branch.