diff --git a/bin/sail b/bin/sail index af31cc0c..1863cfc9 100755 --- a/bin/sail +++ b/bin/sail @@ -116,8 +116,10 @@ else fi # Source the ".env" file so Laravel's environment variables are available... -if [ -f ./.env ]; then - source ./.env +if [ ! -z "$APP_ENV" ] && [ -f ./.env.$APP_ENV ]; then + source ./.env.$APP_ENV; +elif [ -f ./.env ]; then + source ./.env; fi # Define environment variables...