Add run db to connect to the database

This commit is contained in:
Oliver Davies 2024-07-20 13:52:19 +01:00
parent 937f8dce88
commit 97836712f2
2 changed files with 11 additions and 0 deletions

View file

@ -53,6 +53,13 @@ function composer {
_exec php composer "${@}"
}
# Connect to the database.
function db {
[[ -f ".env" ]] && source .env
docker compose exec database mysql -u"$DB_USER" -p"$DB_PASSWORD" "$DB_NAME"
}
function drush {
_exec php drush "${@}"
}