2# Regenerate any files that use Cog.
4# Among other things, this is used to create the per-README list of
5# the individual scripts and files in this repo.
7# Here Cog is Ned Batchelder's file generation tool, described here:
8# https://nedbatchelder.com/code/cog
13if [[ "$@" =~ "--check" ]]; then
16 action="apply_changes"
20# -I = ignore binary files
23 find . -type f -not -path "./.venv/*" -not -path "./.git/*" \
24 -exec grep -rIl "\[\[\[cog" {} + | sort)
27 if [[ $(basename "$f") == "caddyfmt" ]]; then
31 if [[ "$action" == "check_only" ]]; then