PhpStorm protected branches feature

Published on Wednesday 12, December 2018

Recently, while working on a little project, I decided to clean up some of the commits on the master branch before pushing it to Packagist. To be lazy, I decided to use PhpStorm's interactive rebase tool instead of the good ole command line.

BUT I COULD NOT! And I started to go mad.

Thumbnail

It turns out, PhpStorm has a protected branch feature. This stops you from doing silly things on a branch with the VCS capabilities you have available. When I removed master from these settings, I could reword and rebase to my delight.

Thumbnail

I still highly recommend configuring this in your repository settings on Bitbucket, GitLab, GitHub, etc. But it is still a neat (and unknown to myself) feature.