I deleted almost all branches on our team remote repo (github) by running
git push -f --mirror
.
I intended to publish a renamed branch like proposed in a comment on this StackOverflow Question. I didn't read see part:
but you should only use this method if the remote is simply to be a copy of your current repository.
The git output looked like this:
Enumerating objects: 347, done.
Counting objects: 100% (347/347), done.
Delta compression using up to 12 threads
Compressing objects: 100% (323/323), done.
Writing objects: 100% (329/329), 41.10 KiB | 2.28 MiB/s, done.
Total 329 (delta 223), reused 0 (delta 0)
remote: Resolving deltas: 100% (223/223), completed with 14 local objects.
remote: fatal: Invalid revision range 9777ec4fd3478671a130a5977ce1ac5946563795..0000000000000000000000000000000000000000
remote: fatal: Invalid revision range 3d3ee67027e8567e83c279cecba8dcd043414d1b..0000000000000000000000000000000000000000
remote: fatal: Invalid revision range 580282c713107ee5e20ca339634cae3ef623dc4f..0000000000000000000000000000000000000000
[...]
To https://github.com/.../.git
- [deleted] A
- [deleted] B
- [deleted] C
[...]
- [new branch] localBranch -> localBranch
- [new branch] origin/A -> origin/A
- [new branch] origin/B -> origin/B
- [new branch] origin/C -> origin/C
[...]
Is there a way to restore the branches? And does [new branch] origin/C -> origin/C
mean, that this branch is now somewhere (where I can't find it)?
I'm really thankful for your help!