by Devin Yang
(This article was automatically translated.)

Published - 4 years ago ( Updated - 4 years ago )

Save .env content to system environment variables
For example, I have a .env file with the following contents:
test1=abc
test2=def
Execute the following command:
export $(grep -v '^#' .env | xargs)
You can see this environment variable on your host side.
Execute env to view
env

Tags: linux

Devin Yang

Feel free to ask me, if you don't get it.:)

No Comment

Post your comment

Login is required to leave comments

Similar Stories


Laravel linux

My mobile computer, install Laravel 8 on Sony xperia 5 II

This is my first Android phone. It's no problem to try to install Laravel. Basically, I installed vim and mariadb. After executing sshd, you can log in through 8022, it is completely a mobile computer: p. The software I use is Termux...

linux

Remove the Linux Kernel that is not used by the old version on Ubuntu

This page describes how I removed the old version of Linux Kernel taking up space on ubuntu.

linux, cli

How to use the find command to find files that have been changed within 7 days

If we have changed some files, how to find out through the command line?