templates - GitHub 拉取请求模板 : get current branch name

标签 templates github branch git-branch pull-request

我正在为我的存储库创建拉取请求模板。

我按照 https://help.github.com/articles/creating-a-pull-request-template-for-your-repository/ 中的说明添加了一个新文件,现在我希望它的主体包含一个使用当前分支名称(拉取请求分支名称)生成的字符串。

在 GitHub 的文档中找不到答案,想知道它是否可能,如果可能,如何?

最佳答案

我在推特上提出了一个问题:“有没有办法在拉取请求模板中获取当前分支名称?”

提到 GitHub 帐户,这是我得到的答案:

No, there currently isn't but if this is something you want included in all pull request submissions, you might want to check out Probot: https://probot.github.io . I recently created https://github.com/probot/view-rendered … that edits the pull request body to add rendered links for docs.



推文链接:https://twitter.com/korndaniel1/status/1022468460226469888

关于templates - GitHub 拉取请求模板 : get current branch name,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51540821/

相关文章:

git - 推送失败后如何撤消提交?

git - 在 Git 中处理临时更改(不提交)

jquery - 使用 jquery 的 html 模板

ios - 如果点击 iOS 屏幕上的任何其他地方,是否会关闭菜单?

c++ - 用 swig 包装专门的 c++ 模板类

java - Gradle/Jenkins JAR发布到GitHub

branch - 如何使用 EGit 创建一个新的远程分支?

branch - 如何使用非标准 svn 存储库布局的 git-svn 访问 svn 分支?

python - 使用通用 View 时模板不存在

c++ - 将 operator== 重载为带有模板参数的自由函数的语法是什么?