似乎你必须与github.com交互来发起一个拉请求。是这样吗?
当前回答
使用Hub命令行包装器,您可以将其链接到git,然后就可以执行 git pull请求
从hub的手册页:
git pull-request [-f] [TITLE|-i ISSUE|ISSUE-URL] [-b BASE] [-h HEAD]
Opens a pull request on GitHub for the project that the "origin" remote points to. The default head of the pull request is the current branch. Both base and head of the pull request can be explicitly given in one of the following formats: "branch", "owner:branch",
"owner/repo:branch". This command will abort operation if it detects that the current topic branch has local commits that are not yet pushed to its upstream branch on the remote. To skip this check, use -f.
If TITLE is omitted, a text editor will open in which title and body of the pull request can be entered in the same manner as git commit message.
If instead of normal TITLE an issue number is given with -i, the pull request will be attached to an existing GitHub issue. Alternatively, instead of title you can paste a full URL to an issue on GitHub.
其他回答
我以前用过这个工具-虽然看起来需要先打开一个问题,但如果你使用github问题跟踪,它非常有用,真的简化了工作流程。Git打开拉取,然后从你所在或选择的分支提交一个拉取请求。 https://github.com/jehiah/git-open-pull
编辑:看起来你可以在飞行中创建问题,所以这个工具是一个很好的解决方案。
使用Hub命令行包装器,您可以将其链接到git,然后就可以执行 git pull请求
从hub的手册页:
git pull-request [-f] [TITLE|-i ISSUE|ISSUE-URL] [-b BASE] [-h HEAD]
Opens a pull request on GitHub for the project that the "origin" remote points to. The default head of the pull request is the current branch. Both base and head of the pull request can be explicitly given in one of the following formats: "branch", "owner:branch",
"owner/repo:branch". This command will abort operation if it detects that the current topic branch has local commits that are not yet pushed to its upstream branch on the remote. To skip this check, use -f.
If TITLE is omitted, a text editor will open in which title and body of the pull request can be entered in the same manner as git commit message.
If instead of normal TITLE an issue number is given with -i, the pull request will be attached to an existing GitHub issue. Alternatively, instead of title you can paste a full URL to an issue on GitHub.
最后我自己做了,我发现它比周围的其他解决方案更好。
https://npmjs.org/package/pullr
我使用简单的别名来创建拉请求,
alias pr='open -n -a "Google Chrome" --args "https://github.com/user/repo/compare/pre-master...nawarkhede:$(git_current_branch)\?expand\=1"'
更新:hub命令现在是一个官方的github项目,也支持创建拉请求
原:
似乎在hub命令中添加一个特别有用的东西:http://github.com/defunkt/hub或github gem: http://github.com/defunkt/github-gem
我建议将问题提交给那些需要它的项目。github的人都很有反应。
推荐文章
- Bower: ENOGIT Git未安装或不在PATH中
- Bitbucket上的Git:总是要求密码,即使上传了我的公共SSH密钥
- Git别名-多个命令和参数
- 如何添加一个“打开git-bash这里…”上下文菜单到windows资源管理器?
- 新Github项目发布通知?
- 是否可以在Git中只提取一个文件?
- 当我做“git diff”的时候,我怎么能得到一个并排的diff ?
- 在git中如何将提交移动到暂存区?
- 如何缩小。git文件夹
- 如何在本地删除分支?
- 找到包含特定提交的合并提交
- Windows上Git文件的权限
- 如何从一个枝头摘到另一个枝头
- 如何获得在两次Git提交之间更改的所有文件的列表?
- 什么是跟踪分支?