DEV Community

RR Joson
RR Joson

Posted on

3

Keep your repository clean by automatically deleting GitHub branches

Have you ever found your GitHub repo having too many branches? Was it because you and your teammates keep forgetting to delete a branch after it gets merged?

You can fix this in 3 easy steps:

  1. On GitHub, navigate to the main page of the repository.
  2. Under your repository name, click "Settings".
  3. Under "Merge button", select or unselect "Automatically delete head branches"

Now, the next time you merge a branch, it will get automatically deleted. Keeping your repository from having too many branches.

Thanks for reading. Did this help you out? If it did, I hope you consider sharing it. You might help someone else out. Thanks so much!

Reference: https://help.github.com/en/articles/managing-the-automatic-deletion-of-branches

Hostinger image

Get n8n VPS hosting 3x cheaper than a cloud solution

Get fast, easy, secure n8n VPS hosting from $4.99/mo at Hostinger. Automate any workflow using a pre-installed n8n application and no-code customization.

Start now

Top comments (0)

AWS Security LIVE!

Join us for AWS Security LIVE!

Discover the future of cloud security. Tune in live for trends, tips, and solutions from AWS and AWS Partners.

Learn More

Instrument, monitor, fix: a hands-on debugging session

Join Lazar for a hands-on session where you’ll build it, break it, debug it, and fix it. You’ll set up Sentry, track errors, use Session Replay and Tracing, and leverage some good ol’ AI to find and fix issues fast.

Tune in to the full event

DEV is partnering to bring live events to the community. Join us or dismiss this billboard if you're not interested. ❤️