github / safe-settings

ISC License
561 stars 137 forks source link

Add code to handle both rename and reassign of default branch #632

Closed decyjphr closed 1 month ago

decyjphr commented 1 month ago

Handle both rename and reassignment of default branch. If it is reassigned and repository settings has a default-branch then safe-settings will reset it back.

If it is a rename of the current default branch, safe-settings will rename it back.

Any new refs that are created by the user will still remain as they would be pointing to the current default branch and cannot be deleted.