Issue
Is there a way to find the name of the bash configuration file that is currently on use. I searched for the .profile or .bashrc but did not find them. However still I can print some of the env variables i.e $HOME, $PATH
Solution
If you are using one of these sudo su -
, bash --login
, ssh user@host
,
these are considered as login shell,
then you might want to try
- /etc/profile
- ~/.bash_profile
- ~/.bash_login
- ~/.profile
Answered By - ajreal Answer Checked By - Willingham (WPSolving Volunteer)