Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Previously not pushed commits disappeared when a new commit is forcefully pushed by terminal #9

Open
SamirPaulb opened this issue Feb 16, 2021 · 0 comments

Comments

@SamirPaulb
Copy link
Owner

Previously I was coping pasting my codes in GitHub and then saving that. I committed 90 files by this same process. But when I commit a new file by git command in terminal then it was showing an error but I forcefully pushed that. After that my previous commits disappears and it is now showing no remaining existence of that previous commits and the git pull is also not working here.
If you have any Idea to recover that previous commits then help me to restore my previous commits.
`` `git stash
git checkout some-branch
git stash pop

``git log --oneline -n1 # this will give you the SHA
git checkout some-branch
git merge ${commit-sha}`

-> not working

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant