我需要恢复在推送过程中以某种方式删除的两个Git分支.
这两个分支是在不同的系统上创建的,然后推送到我的"共享"(github)存储库.
在我的系统上,我(显然)在获取期间检索了分支:
~/myfolder> git fetch
remote: Counting objects: 105, done.
remote: Compressing objects: 100% (58/58), done.
remote: Total 62 (delta 29), reused 0 (delta 0)
Unpacking objects: 100% (62/62), done.
From github.com:mygiturl
* [new branch] contact_page -> origin/contact_page
731d1bb..e8b68cc homepage -> origin/homepage
* [new branch] new_pictures -> origin/new_pictures
Run Code Online (Sandbox Code Playgroud)
在那之后,我做了一个推动,将我的本地更改发送到中央仓库.出于某种原因,这些分支从我的本地系统和中央仓库中删除:
~/myfolder> git push
Counting objects: 71, done.
Delta compression using up to 2 threads.
Compressing objects: 100% (43/43), done.
Writing objects: 100% (49/49), 4.99 KiB, done.
Total 49 (delta 33), …Run Code Online (Sandbox Code Playgroud)