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

master branch getting deleted #21

Closed
ctrom opened this issue Sep 11, 2018 · 5 comments
Closed

master branch getting deleted #21

ctrom opened this issue Sep 11, 2018 · 5 comments

Comments

@ctrom
Copy link

ctrom commented Sep 11, 2018

Since installing this plugin, we've been having issues with our master branches getting deleted.

Example Scenario:

  1. Repository has its default branch set to master.
  2. User1 makes a PR from their fork (User1 wants to merge 1 commit into OrgName:master from User1:master).
  3. PR gets merged.
  4. OrgName:master branch is deleted and the default branch is set to one of the other branches on the repository.

Our testing indicates that this issue does not occur if the PR is from a non-master fork branch (User1 wants to merge 1 commit into OrgName:master from User1:NewFeatureBranch).

@SvanBoxel
Copy link
Owner

SvanBoxel commented Sep 11, 2018

Although people threat branches named master in a special way, from a git point-of-view it's just a normal branch. Have you looked into Protected branches? That should prevent this problem.

@ctrom
Copy link
Author

ctrom commented Sep 11, 2018

Perhaps I'm misunderstanding how this tool is supposed to work. If User1:master is getting merged into OrgName:master, I would think we would want to keep OrgName:master around (since we just merged into it). If we were merging OrgName:master into OrgName:ReleaseBranch, I can understand deleting master because we've just updated another branch to contain master's changes, but that isn't what we're experiencing.

@SvanBoxel
Copy link
Owner

SvanBoxel commented Sep 11, 2018

You're right @ctrom, this sounds like a bug. Let me try to reproduce it. Also, feel free to submit a PR. 👍 https://github.com/SvanBoxel/delete-merged-branch/releases/tag/v1.0.3

@SvanBoxel
Copy link
Owner

Hey @ctrom, I just released a new version that includes this bug fix.

@ctrom
Copy link
Author

ctrom commented Sep 13, 2018

@SvanBoxel Awesome, thanks for getting this fixed so fast.

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

No branches or pull requests

2 participants