Created
February 26, 2022 06:41
-
-
Save CypherpunkSamurai/be805aa762cd4bb2ac3d0dca48e0fb04 to your computer and use it in GitHub Desktop.
Diff Local Repo to Remote Repo
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # add the remote | |
| git remote add b https://remote_repo.git | |
| # fetch remote commits | |
| git remote update | |
| # uses current branch for diffing | |
| git diff $(git branch --show-current) remotes/b/remote_repo_branch > diff.diff\ | |
| # remove the remote for cleanup | |
| git remote rm b |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment