Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
在 git 中是git diff <file path>,但是在 tig 中呢?
git diff <file path>
在 tig 中,在状态视图中,突出显示文件(已暂存或未暂存)并按D,比较最后一次提交。我认为它应该将未提交的文件与该文件的最后提交版本进行比较。
作为一个黑客,你可以git diff <file path> | tig看到它。
git diff <file path> | tig
在中的status部分中,tig您可以看到暂存和未暂存的更改(例如git diffvs )在文件出现的每个部分(在“要提交的更改”或“已更改但未更新”下)中git diff --cached按下文件。Enter
status
tig
git diff
git diff --cached
这可能是一个不错的功能,tig diff -- <file path>但是,好吧 - 继续,编码:)
tig diff -- <file path>