Help
cancel
Showing results for 
Search instead for 
Did you mean: 
Ground Controller Lvl 1
Message 11 of 16

Re: Apply branch protection to two branches with entirely different names.

Would love this as well

Community Manager
Message 12 of 16

Re: Apply branch protection to two branches with entirely different names.

Hi @jeffaburt and @trusktr,

 

Thanks for being here, we actually  have an internal issue discussing this possibility and I've added your feedback to it.  Thanks again for reaching out! I'll come back and post any updates here.

Thanks for being here, sharing, and keeping our community awesome!
Best,
AndreaG

Mark helpful posts with Accept as Solution to help other users locate important info. Don't forget to give Kudos for great content!

Copilot Lvl 2
Message 13 of 16

Re: Apply branch protection to two branches with entirely different names.

@AndreaGriffiths11 

Another +1 for getting this enabled.  

I am preparing a migration of 100+ repos to GitHub Enterprise.  The inability to automate (via REST API) branch protection rules for wildcard patterns (such as release/* and feature/*) is going to be major painpoint for us.  

Ground Controller Lvl 1
Message 14 of 16

Re: Apply branch protection to two branches with entirely different names.

@tadms  I think the wildcard patterns support is already available and documented here: https://help.github.com/en/articles/configuring-protected-branches

 

The request still pending here is for multiple name matches such as a regex OR.   I supposed you could be looking for this?  {release/*,feature/*}   Would this also be supported?

Copilot Lvl 2
Message 15 of 16

Re: Apply branch protection to two branches with entirely different names.

Yes, this is possible through the UI.  But I'm not looking to manually do this 100+ times through the UI. 

 

My request is to have this functionality with the REST API to be able to do this programmatically (originally requested by ksraju-rms in this thread).  

Ground Controller Lvl 1
Message 16 of 16

Re: Apply branch protection to two branches with entirely different names.

Hello! @AndreaGriffiths11 :)

What is the current status of that feature? Where can it be discussed? It would be awesome to be able to use a pattern like `{master,release/*,v[0-9]*}`.