我使用tig查看更改内容。但是如何在更改的文件列表中显示完整路径而不是仅显示长文件路径的一部分?
例如,我想查看SpecialAnswList.java的完整路径,而不是...前缀。
---
│ .../ui/component/SpeciaAnswList.java | 44 ++++++++--------------
│ 1 file changed, 16 insertions(+), 28 deletions(-)
答案 0 :(得分:2)
由于Tig使用git-show(1)来显示差异,因此可以使用--stat
diff选项。例如:
$ tig --stat=200,180
不幸的是,没有选项可以按百分比进行缩放,因此您必须手动执行此操作。
以下是该选项的文档:
--stat[=<width>[,<name-width>[,<count>]]]
Generate a diffstat. By default, as much space as necessary will be used for the
filename part, and the rest for the graph part. Maximum width defaults to terminal
width, or 80 columns if not connected to a terminal, and can be overridden by
<width>. The width of the filename part can be limited by giving another width
<name-width> after a comma. The width of the graph part can be limited by using
--stat-graph-width=<width> (affects all commands generating a stat graph) or by
setting diff.statGraphWidth=<width> (does not affect git format-patch). By giving a
third parameter <count>, you can limit the output to the first <count> lines,
followed by ... if there are more.
These parameters can also be set individually with --stat-width=<width>,
--stat-name-width=<name-width> and --stat-count=<count>.