https://github.com/chmodshubham/diff_frepo_vs_orepo
To check the difference between the forked repository with the original repository just like `git diff` command
https://github.com/chmodshubham/diff_frepo_vs_orepo
difference gitdiff
Last synced: 3 months ago
JSON representation
To check the difference between the forked repository with the original repository just like `git diff` command
- Host: GitHub
- URL: https://github.com/chmodshubham/diff_frepo_vs_orepo
- Owner: chmodshubham
- Created: 2023-03-30T20:36:20.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2023-03-30T21:09:33.000Z (almost 3 years ago)
- Last Synced: 2024-04-16T04:13:10.337Z (almost 2 years ago)
- Topics: difference, gitdiff
- Homepage:
- Size: 2.93 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Compare forked repository w.r.t. original repository
To check the difference between your forked repository and the original one, you can follow these steps:
### 1. Clone your forked repository to your local machine using the `git clone` command.
```
git clone https://github.com/yourusername/yourforkedrepo.git
cd yourforkedrepo/
```
### 2. Add the original repository as a remote using the `git remote add` command.
```
git remote add upstream https://github.com/originaluser/originalrepo.git
```
### 3. Fetch the latest changes from the original repository using the `git fetch` command.
```
git fetch upstream
```
### 4. Check out your local branch that you want to compare to the original repository using the `git checkout` command.
```
git checkout yourRepoBranch
```
### 5. Compare your local branch with the specific branch of the original repository that you want to compare with, using the `git diff` command.
```
git diff upstream/originalRepoBranch
```
Store them in a file:
```
git diff upstream/originalRepoBranch >> diff.txt
```