Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Triggering jobs

on: push
  • Multiple events
on: [push, pull_request]

Also:

on:
    push:
    pull_request:
    workflow_dispatch:
  • Run on "push" in every branch.
  • Run on "pull_request" if it was sent to the "dev" branch.
  • workflow_dispatch to run manually via the web site of GitHub.
  • Scheduled every 5 minutes (cron config)
name: Triggers

on:
  push:
    branches: '*'
  pull_request:
    branches: 'dev'
  workflow_dispatch:
  schedule:
    - cron: '*/5 * * * *'

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
    - name: Look around
      run: |
        echo $GITHUB_EVENT_NAME
        printenv | sort

  • Manual events (via POST request)