Skip to content

Commit d18da6b

Browse files
authored
Update notes on push event behavior in workflows
Note that workflows can be triggered by pushes to non-default branches.
1 parent 776583f commit d18da6b

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

content/actions/reference/workflows-and-actions/events-that-trigger-workflows.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -844,6 +844,9 @@ on:
844844
> [!NOTE]
845845
> When a `push` webhook event triggers a workflow run, the Actions UI's "pushed by" field shows the account of the pusher and not the author or committer. However, if the changes are pushed to a repository using SSH authentication with a deploy key, then the "pushed by" field will be the repository admin who verified the deploy key when it was added it to a repository.
846846

847+
> [!NOTE]
848+
> You can use `push` to trigger a workflow that has not been merged to the default branch. This can be useful when you want to test a workflow but cannot merge it into the default branch.
849+
847850
### Running your workflow only when a push to specific branches occurs
848851

849852
You can use the `branches` or `branches-ignore` filter to configure your workflow to only run when specific branches are pushed. For more information, see [AUTOTITLE](/actions/using-workflows/workflow-syntax-for-github-actions#onpushbranchestagsbranches-ignoretags-ignore).

0 commit comments

Comments
 (0)