Skip to content

GitHub Actions: Better support for alternative default branch names

We’ve made some changes in GitHub Actions to better support communities who have chosen to move away from using master as their default branch name.

We have updated all of our starter workflows to use a new $default-branch macro rather than the previously hardcoded master. You can take advantage of this feature in your custom starter workflow templates as well.

In addition, we have renamed the default branch for most of the GitHub-authored actions from master to main. All of your workflows that reference the old branch name will still work. However, you’ll see a prompt to change to the new name when you edit the workflow on the web.

This change is one of many changes GitHub is making to support projects and maintainers that want to rename their default branch. To learn more about the changes we’re making, see github/renaming.

Secret leaks are one of the most common security mistakes, and they can have disastrous consequences. GitHub Secret Scanning looks for leaked secrets in all public repositories, and enrolled private repositories, and works with the issuer to notify the developer and/or revoke the token as appropriate. This protects users from fraud and data leaks.

In addition to our 24 existing partners, GitHub has partnered with Shopify, MessageBird, Dynatrace, SSLMate and to scan for their developer tokens! This brings our total number of token scanning partners to 29.

See more