Git reset in detached HEAD state -
i understand git reset
command moves branch backwards in history (*), , branch moves 1 head
pointing to.
so got curious , tried call in detached head state
see happen. expecting error git did something, , i'm unable figure out did.
did git acted head
still pointing before checked out , went detached head state
?
[ edit 1 ] figured out. same when 1 not in detached head state, except doesnt move branch backward. it's the
[ edit 2(*) ] git reset
moves branch backward in history when specifying older commit. when doing git reset head
, leaves branch (see comments below).
git reset
makes current branch , head move specific commit. if it's detached head, makes head move.
Comments
Post a Comment