This action creates a new branch with the same commit reference as the branch it is being ran on, or your chosen reference when specified.
NAME | DESCRIPTION | TYPE | REQUIRED | DEFAULT |
---|---|---|---|---|
GITHUB_TOKEN |
GitHub Actions Token | string |
true |
|
branch |
The name of the branch to create. | string |
false |
release-candidate |
sha |
The SHA1 value for the branch reference. | string |
false |
NAME | DESCRIPTION | TYPE |
---|---|---|
created |
Boolean value representing whether or not a new branch was created. | bool |
uses: dmsi-io/gha-create-branch@main
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
branch: 'release-notes'
For a further practical example, see .github/workflows/test-run.yaml.