I have a config file which I can $source and check the variable values in it. However, I do not want to contaminate my current shell environment while still want to check the value of the variables.
Any suggestions?
I have a config file which I can $source and check the variable values in it. However, I do not want to contaminate my current shell environment while still want to check the value of the variables.
Any suggestions?
Just start a second shell.
[root@feaf38f55954 ~]# cat envars
export BOOGER='yuck'
[root@feaf38f55954 ~]# env | grep BOOGER
[root@feaf38f55954 ~]# bash
[root@feaf38f55954 ~]# source envars
[root@feaf38f55954 ~]# env | grep BOOGER
BOOGER=yuck
[root@feaf38f55954 ~]# exit
exit
[root@feaf38f55954 ~]# env | grep BOOGER
[root@feaf38f55954 ~]#