build-configs/templates/terraform/run.twig
Oliver Davies b1571f3174 refactor(run): change set statements
Use the long form name for each option instead of short hand names or a
combination of both - e.g. `set -eu` and `set -o pipefail`.
2023-11-22 21:53:50 +00:00

34 lines
622 B
Twig
Executable file

#!/usr/bin/env bash
# {{ managedText | raw }}
set -o errexit
set -o pipefail
# Disable Git hooks.
function git-hooks:off {
git config --unset core.hooksPath
}
# Enable Git hooks.
function git-hooks:on {
git config core.hooksPath .githooks
}
# Display a list of all available commands.
function help {
printf "%s <task> [args]\n\nTasks:\n" "${0}"
compgen -A function | grep -v "^_" | cat -n
printf "\nExtended help:\n Each task has comments for general usage\n"
}
# Include any local tasks.
[[ -e run.local ]] && source run.local
TIMEFORMAT=$'\nTask completed in %3lR'
time "${@:-help}"
# vim: ft=bash