Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support other default branches #123

Closed
skeggse opened this issue Mar 24, 2021 · 6 comments · Fixed by #124
Closed

Support other default branches #123

skeggse opened this issue Mar 24, 2021 · 6 comments · Fixed by #124

Comments

@skeggse
Copy link

skeggse commented Mar 24, 2021

We use next-master for our primary development branch; some places use develop or main or default. It'd be great if the Open Remote URL in Browser (master) and related commands could be configured to use a different branch.

@frjo
Copy link

frjo commented Jun 24, 2021

I would like this as well, all the repos I work on use "main".

@MaxPhilips
Copy link
Collaborator

I will have some time tomorrow August 6th to take a stab at this! I've been using this plugin recently on repos with other default branch names

@MaxPhilips
Copy link
Collaborator

@bgreenlee if you have a minute, could you check out the PR I've opened for this issue? thanks for the useful plugin!

@nightpool
Copy link

nightpool commented Sep 28, 2021

It would be really useful to detect this on a repo-by-repo basis, this change broke my workflow by changing "default" default branch from master to main. I'm in the progress of migrating my repos, but it would be great to have this "just work" automatically based on how the repo is configured. git symbolic-ref refs/remotes/origin/HEAD should be able to return the name of the github default branch for a given repository (if your GitHub remote is named origin). In the Github repo API response, it's available as default_branch. Not sure which approach would work best for the plugin, but having only one global "default branch" configuration variable is a little annoying when moving between projects.

@MaxPhilips
Copy link
Collaborator

MaxPhilips commented Sep 29, 2021 via email

@nightpool
Copy link

Yeah, I was eventually able to find the option and switch it back as a short-term workaround, since I'm just working in the one repo right now, but I can imagine it's going to continue being more and more of a pain as I move from repo to repo and have to keep updating it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants