Interview Prep/CI/CD/GitHub Actions

What is `workflow_dispatch` and how are inputs used?

BeginnerConceptGitHub Actions
Answer

workflow_dispatch adds a "Run workflow" button (and API/CLI trigger) so a workflow can be started manually, with typed inputs (string, boolean, choice, environment). Inputs are read from inputs.<name>. From the CLI: gh workflow run deploy.yml -f env=staging -f version=1.4.2. The workflow file must exist on the default branch for the button to appear.

All CI/CD questions

More on GitHub Actions