HEAD〜vs HEAD ^ vs HEAD @ {}也称为波浪号vs插入符vs at符号 [英] HEAD~ vs HEAD^ vs HEAD@{} also known as tilde vs caret vs at sign
本文介绍了HEAD〜vs HEAD ^ vs HEAD @ {}也称为波浪号vs插入符vs at符号的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
HEAD是当前分支的指针.我已经见过HEAD祖先的各种记号,包括
HEAD is a pointer at the current branch. I have seen a variety of notations for ancestors of HEAD including
-
HEAD~2
-
HEAD^2
-
HEAD@{2}
-
HEAD~~
-
HEAD^^
HEAD~2
HEAD^2
HEAD@{2}
HEAD~~
HEAD^^
以上每一个到底是什么意思?该文件在哪里?
What does each of the above mean, exactly? Where is the documentation for this?
推荐答案
从文档此处.
-
HEAD~2
:2提交早于HEAD -
HEAD^2
:HEAD的第二个父级,如果HEAD是合并的,否则是非法的 -
HEAD@{2}
:指git reflog
概述中的第3个清单
-
HEAD~~
:2提交早于HEAD -
HEAD^^
:2提交早于HEAD
HEAD~2
: 2 commits older than HEADHEAD^2
: the second parent of HEAD, if HEAD was a merge, otherwise illegalHEAD@{2}
: refers to the 3rd listing in the overview ofgit reflog
HEAD~~
: 2 commits older than HEADHEAD^^
: 2 commits older than HEAD
如果HEAD是合并的,则
If HEAD was a merge, then
- 第一父级是我们合并到的分支
- 第二个父级是我们合并的分支.
- first parent is the branch into which we merged,
- second parent is the branch we merged.
一些组合和同义词
First Parent First Grandparent Second Parent Second Grandparent
HEAD~
HEAD^
HEAD~1 HEAD~2 HEAD^2 HEAD^2~
HEAD^1 HEAD^^ HEAD^2^
这篇关于HEAD〜vs HEAD ^ vs HEAD @ {}也称为波浪号vs插入符vs at符号的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文