4 ms·
For what it's worth, you could have looked at the reflog of the git repo on the server and it would still have a reference (the hexadecimal hash) to the develo
by herge 11y ago
For what it's worth, you could have looked at the reflog of the git repo on the server and it would still have a reference (the hexadecimal hash) to the develop branch before your git push -f.
- mmanfrin 11y agoWe had the hash, but no one had it locally and we could not pull it down since I had overwritten the history.
- simoncion 11y agoThis isn't a criticism. I'm either missing info, and am making a fool of myself, or telling you about something you didn't know was possible: You either had git configured on the server to git-gc after every push, or were unable to ssh into the server? If neither one of those is true, then -IIRC- you could have either: 1) Logged in to the server, rewritten the affected repo's branch to point to the pre-disaster commit hash. 2) Pull down the repo's .git directory from the server, rewrite the branch, and force push that. Would either one of those have been more work than working with your CI system?