In git, I can specify the previous revision by saying HEAD^
or HEAD~1
. What about going the other way? Suppose I\'m on revision X, and I do git c
I don't think this is possible, since a Git commit only stores its parent commit, but not its children.
Imagine a commit would store its children. What would happen if you would create several branches off this commit, so multiple commits have this commit as parent? What would then be "HEAD+"? This is ambiguous and wrong.
Speaking in what I know from data structures: Git stores history as a single-linked list, whereas you operation would need a doubly-linked list.