Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upPublish to GitHub uses master instead of default #105025
Comments
|
(Experimental duplicate detection) |
|
It looks like it always uses vscode/extensions/github/src/publish.ts Line 178 in b58f454 I am not entirely sure how to get the current branch to make a PR though. |
|
In order to get the current branch, I think that we could use the method below to get the global configuration and then, based on the vscode/extensions/github/src/typings/git.d.ts Line 152 in b58f454 |
|
No, I would actually try to get the name of the current branch from the repo itself with |
|
I do not know how helpful this is, but GitHub links to this page as their official updates on how they are defaulting to There is useful guidance on there, but it is not directed at developers who are creating tooling like VSC. Of course, GitHub is also enabling any default branch, which is why my concern with VSC is not just supporting |
|
The PR I submitted will use whatever branch name is configured. Whether it is |
|
Thanks! |


Issue Type: Bug
git config --global init.defaultBranch mainmasterbranch. Oddly, you cannot select a new default branch with this use case (at least right now?)Note: I tried the
Publish branchoption, but received errors informing me I had to pull, which resulted in additional errors. Ultimately it seems to have worked(?), but it does not feel like a good workflow. I think most people like myself will want to use the Publish to GitHub option and have it automatically sort out the fact you are pushing the configured default branch.VS Code version: Code 1.48.0 (db40434, 2020-08-13T08:03:27.059Z)
OS version: Darwin x64 19.6.0
Extensions (4)