2020-06-24 17:22:28 +02:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
|
2022-05-23 16:29:10 +02:00
|
|
|
docker-compose()
|
|
|
|
{
|
|
|
|
if ! docker compose version 1>/dev/null 2>/dev/null
|
|
|
|
then
|
2022-05-25 09:53:25 +02:00
|
|
|
if ! command docker-compose version 1>/dev/null 2>/dev/null
|
2022-05-23 16:29:10 +02:00
|
|
|
then
|
|
|
|
echo -e "\e[91m[ ❌ ] docker-compose was not found, exiting...\e[39m" && exit 1
|
|
|
|
else
|
2022-05-25 09:53:25 +02:00
|
|
|
command docker-compose "$@"
|
2022-05-23 16:29:10 +02:00
|
|
|
fi
|
|
|
|
else
|
|
|
|
docker compose "$@"
|
|
|
|
fi
|
|
|
|
}
|
|
|
|
|
|
|
|
docker-compose exec -T postgres psql -Upostgres -c \\dFd | head -n -2 | tail -n +3 | awk '{ print gensub(/([a-z]+)_stem/,"\\1","g",$3); }'
|