Skip to content

Instantly share code, notes, and snippets.

@tbnorth
Last active October 13, 2025 16:53
Show Gist options
  • Save tbnorth/8f4f0ddde64eeaac326caeec2adcf4c5 to your computer and use it in GitHub Desktop.
Save tbnorth/8f4f0ddde64eeaac326caeec2adcf4c5 to your computer and use it in GitHub Desktop.
disable all GitHub workflows on all repos. with gh CLI
# Get a current list of repos.
gh search repos --limit 1000 @tbnorth | sed 's/\s.*//' | tee repos.list.202510
# Get a list of workflows including repo. names.
< repos.list.202510 xargs -IF bash -c 'echo REPO F ; gh workflow list --repo F' \
| tee workflows.list.202510
# Disable all active workflows.
sed -En <workflows.list.202510 \
'/REPO/ {s/.*\s//; h}; /active/ {s/.*\s/gh workflow disable /; s/$/ --repo /; G; s/\n//; p}' \
| bash
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment