dolthub / dolthub/doltlab-issues

start-doltlab.sh should use .env

Open
#55 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
10
Forks
1
PR merge metrics
No merged PRs in 30d

Description

The start doltab shell script should use .env files by default if found so that server admins only have to set these once and run the script instead of constantly setting these env vars.

I suggest something like the following code:

```
unamestr=$(uname)
if [ -f .env ]; then
echo 'environment file found'
if [ "$unamestr" = 'Linux' ]; then
export $(grep -v '^#' .env | xargs -d '\n')
elif [ "$unamestr" = 'Darwin' ]; then
export $(grep -v '^#' .env | xargs -0)
fi
fi
```

this would load the .env into the environment at runtime

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.