It's very common that, after pushing a given branch upstream, I'll want to visit it on github and create a pull request. I'm starting to get annoyed at having to manually visit the repo, find the branch, and create the PR.
Q: How can I write a command that visits the PR url in a browser?
The PR url is given by
https://github.com/ORIGIN-REPO/compare/BRANCH-NAME. Since both the
origin and the
branch-name known by Magit (and by plain
git), it should be easy to write a command that builds that URL and calls
browse-url on it.
Unfortunately, I know nothing about the internals workings of Magit, so I don't know how to get that information.