


Most GitHub events are triggered by more than one type of activity. Selects the types of activity that will trigger a workflow run. on: # Trigger the workflow on push or pull request, # but only for the main branch push: branches: - main pull_request: branches: - main # Also trigger on page_build, as well as release created events page_build: release: types: # This configuration does not affect the page_build event above - created on.types You must append a colon ( :) to all events, including events without configuration. If you need to specify activity types or configuration for an event, you must configure each event separately.
ACTION STRINGS PHRASES WONT WORK CODE
For a list of available events, see " Events that trigger workflows." Example: Using a single event # Triggered when code is pushed to any branch in a repository on: push Example: Using a list of events # Triggers the workflow on push or pull request events on: Įxample: Using multiple events with activity types or configuration You can provide a single event string, array of events, array of event types, or an event configuration map that schedules a workflow or restricts the execution of a workflow to specific files, tags, or branch changes. The name of the GitHub event that triggers the workflow. If you omit name, GitHub sets it to the workflow file path relative to the root of the repository. GitHub displays the names of your workflows on your repository's actions page. github/workflows directory of your repository. If you're new to YAML and want to learn more, see " Learn YAML in Y minutes." Workflow files use YAML syntax, and must have either a.
