Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/ssl/3.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分支的描述?_Git - Fatal编程技术网

如何检索Git分支的描述?

如何检索Git分支的描述?,git,Git,Git支持分支描述。可以使用git branch--edit description编辑它们 如何从命令行检索该描述以供其他shell实用程序使用 一种方法是在调用git branch--edit description之前,将$EDITOR(或core.EDITOR)临时设置为cat或等效值,但这有点侵入性,它会返回几个我希望不使用的注释行(即使没有更好的方法,过滤它们也是一种选择)。这很有效,我会接受堆栈溢出允许我这样做。这很有效,我会接受堆栈溢出允许我这样做。 git config --g

Git支持分支描述。可以使用git branch--edit description编辑它们

如何从命令行检索该描述以供其他shell实用程序使用


一种方法是在调用
git branch--edit description
之前,将
$EDITOR
(或core.EDITOR)临时设置为
cat
或等效值,但这有点侵入性,它会返回几个我希望不使用的注释行(即使没有更好的方法,过滤它们也是一种选择)。

这很有效,我会接受堆栈溢出允许我这样做。这很有效,我会接受堆栈溢出允许我这样做。
git config --get-all branch.$branch.description