How do i sync unsynced commits in GitHub for Windows?
i made some changes to a file a month ago. i just realized today that they didn't go anywhere; the GitHub web-site has no history of my changes.
The client has no indication that anything is out of date (there are no "uncommitted changes"). But there are "unsynced commits":
How do i sync unsynced commits?
i tried clicking the sync
button (whatever that means), but all i get (after a progress bar moves for about 7 seconds) is:
failed to sync branch
You might need to open a shell and debug the state of this repo.
Clicking OPEN SHELL, causes a powershell prompt to appear, where i type:
debug the state of this repo
But that doesn't seem to do it:
How do i sync unsynced commits in the GitHub for Windows client?
On GitHub, navigate to the main page of the forked repository that you want to sync with the upstream repository. Select the Sync fork dropdown. Review the details about the commits from the upstream repository, then click Update branch.
In GitHub Desktop, use the Current Branch drop-down, and select the local branch you want to update. To pull any commits from the remote branch, click Pull origin or Pull origin with rebase. Resolve any merge conflicts in your preferred way, using a text editor, the command line, or another tool.
To remove the last commit from git, you can simply run git reset --hard HEAD^ If you are removing multiple commits from the top, you can run git reset --hard HEAD~2 to remove the last two commits. You can increase the number to remove even more commits.
Open the Git Shell and type git status
this should give some more details as to what is wrong.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With