Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/git/25.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
如何在将输出推入管道时获得完整的git reflog输出_Git_Git Reflog - Fatal编程技术网

如何在将输出推入管道时获得完整的git reflog输出

如何在将输出推入管道时获得完整的git reflog输出,git,git-reflog,Git,Git Reflog,我怎样才能将git reflog的输出输入到其他一些程序中,而不必复制并粘贴它。当我管道输出时,分支名称突然消失: $ git --no-pager reflog 8c394ee (HEAD -> master) HEAD@{0}: commit: Bar cbf7358 HEAD@{1}: commit (initial): Foo $ git --no-pager reflog | cat 8c394ee HEAD@{0}: commit: Bar cbf7358 HEAD@{1}:

我怎样才能将
git reflog
的输出输入到其他一些程序中,而不必复制并粘贴它。当我管道输出时,分支名称突然消失:

$ git --no-pager reflog
8c394ee (HEAD -> master) HEAD@{0}: commit: Bar
cbf7358 HEAD@{1}: commit (initial): Foo

$ git --no-pager reflog | cat
8c394ee HEAD@{0}: commit: Bar
cbf7358 HEAD@{1}: commit (initial): Foo

我只想能够
grep
在输出中找到特定的分支名称,但这不起作用,因为git在我尝试这样做时会禁用分支名称。

不幸的是,我的客户(2.20.1和2.23.0.rc2.8.gff66981f45)不理解--decorateSorry,我的错:这是
reflog--decoration
,而不是
git--decoration
git --no-pager reflog --decorate | cat