Leave a Comment
Add all lines from a .env file to environment
zsh:
1 |
zsh ./configs/dev/dev.env|sed 's/#1.*$//g'|grep '^[^#]'|grep -v '^$'|sed 's/^/export /g' |
bash:
1 |
bash ./configs/dev/dev.env|sed 's/#1.*$//g'|grep '^[^#]'|grep -v '^$'|sed 's/^/export /g' |
to output to stdout
1 |
cat ./configs/dev/dev.env|sed 's/#1.*$//g'|grep '^[^#]'|grep -v '^$'|sed 's/^/export /g' |
prepend running a command (did not try it, but something similar):
1 |
env $(cat ./configs/dev/dev.env|sed 's/#.*$//g'|grep '^[^#]'|grep -v '^$'|xargs) |
Similar Posts
- None Found
LEAVE A COMMENT
Для отправки комментария вам необходимо авторизоваться.