Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

i'm just not getting what you mean. if i delete a branch, i CAN still see the branch (and its name) the commits belonged to, even if i never had that branch locally.


You can't see its name, try it.


i absolutely can, though. i went through this recently, trying to get back to a commit from nearly a year ago in a repo i'd never touched before.

the annoying part of getting it back was that you can't just do "checkout {name}" you have to do it by the SHA ID and then commit again by the original name, but before all that, you can 100% follow any since-deleted branch by its name. there's just a weird disconnect between viewing its history and having it directly in your hands again.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: