Adding and Tracking Changes with GitHub Pull Requests
- This guide provides a step-by-step process for adding code, reviewing commits, adding more code, reviewing updates, and adding comments in a GitHub Pull Request (PR) web site.
Task: Add more changes and review the PR
1. Adding Code
-
Checkout your local branch:
-
Make changes to your local repository files.
-
Stage the changes:
-
Commit the changes with a descriptive message:
-
Push the changes to the remote branch:
2. Reviewing the Commits
- Navigate to your GitHub repository in a web browser.
- Open the pull request associated with your branch.
- Click on the Commits tab to view all commits made to the branch.
- Review the commit messages and details to ensure they accurately describe the changes.
The PR should display the updated file contents and commit history.
3. Adding More Code
- Make additional changes to your local repository files.
- Stage the changes:
- Commit the changes with a descriptive message:
- Push the new changes to the same branch:
Once again, the PR should display the updated file contents and commit history.
4: Reviewing the Updates
- Refresh the pull request page on GitHub.
- Navigate to the Files Changed tab to review the updated changes.
- Verify that the new changes align with the pull request’s goals and do not introduce issues.