Automatically open a pull request on github by command line

前端 未结 3 1606
执念已碎
执念已碎 2020-12-16 15:36

I\'m using git to versioning a collaborate project.

And I have two remotes. fork is a fork of an project, and origin

相关标签:
3条回答
  • 2020-12-16 15:59

    Finally success

    The first problem is that I was using the key password and not my github password.

    With this structure:

    Private Organization:

    name: Org
    repository: main
    branch: master
    

    Private Fork:

    name: OrgFork (A organization of mine with forks from **Org**) 
    repository: main
    branch: testing
    

    And the other problem is I was needing accept the corrects parameters, the final command looks like this one:

    hub pull-request "Testing pull-request" -b Org:master -h OrgFork:testing
    

    Thx for help @cjc343, @StevenPenny, @desert69 =)

    0 讨论(0)
  • 2020-12-16 16:03

    You should check out hub, a command line tool to interact with GitHub.

    Its README talks about making pull requests.

    0 讨论(0)
  • 2020-12-16 16:05

    Perhaps like this

    curl -X POST -u garoudan -k \
      -d '{"title": "new feature","head": "octocat:new-feature","base": "master"}' \
      https://api.github.com/repos/garoudan/foo/pulls
    

    ref

    0 讨论(0)
提交回复
热议问题