From: Christian Weiske Date: Tue, 17 Mar 2020 10:07:44 +0000 (+0100) Subject: (no commit message) X-Git-Url: https://git.cweiske.de/paste/374.git/commitdiff_plain/HEAD --- diff --git a/setup.sh b/setup.sh index a52a672..55ac215 100644 --- a/setup.sh +++ b/setup.sh @@ -1,3 +1,7 @@ function dbash() { docker exec -it "$1" bash; } _dbash() { cur="${COMP_WORDS[COMP_CWORD]}"; __docker_complete_containers_running; } complete -F _dbash dbash + +# automatically login as www-data user +function dbashwww() { docker exec -it "$1" su -s /bin/bash www-data; } +complete -F _dbash dbashwww