This repository has been archived on 2025-09-29. You can view files and clone it, but you cannot make any changes to it's state, such as pushing and creating new issues, pull requests or comments.
docker-examples/run

29 lines
412 B
Bash
Executable file

#!/bin/bash
set -e
function cmd {
_dc php "${@}"
}
function composer {
cmd composer "${@}"
}
function drush {
cmd php vendor/bin/drush "${@}"
}
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"
}
function _dc {
docker compose run --rm "${@}"
}
eval "${@:-help}"