mirror of
https://github.com/bookwyrm-social/bookwyrm.git
synced 2024-12-22 16:16:39 +00:00
Figured out a way to give a nice error message
This way if we fail to parse old .env's folks should be able to figure it out
This commit is contained in:
parent
e4f2625b02
commit
f5f900a6e7
1 changed files with 12 additions and 3 deletions
15
bw-dev
15
bw-dev
|
@ -1,9 +1,18 @@
|
|||
#!/bin/bash
|
||||
|
||||
# import our ENV variables
|
||||
source .env
|
||||
|
||||
# exit on errors
|
||||
set -e
|
||||
|
||||
# import our ENV variables
|
||||
# catch exits and give a friendly error message
|
||||
function showerr {
|
||||
echo "Failed to load configuration! You may need to update your .env and quote values with special characters in them."
|
||||
}
|
||||
trap showerr EXIT
|
||||
source .env
|
||||
trap - EXIT
|
||||
|
||||
# show commands as they're executed
|
||||
set -x
|
||||
|
||||
function clean {
|
||||
|
|
Loading…
Reference in a new issue