Quantcast
Channel: How to reload .bash_profile from the command line - Stack Overflow
Browsing all 16 articles
Browse latest View live

Answer by tsujp for How to reload .bash_profile from the command line

Simply re-sourcing the file won't "reload" in the sense that something is first unloaded, then loaded again. If that is what you want you can do:hash -r && _SHOW_MESSAGES=1 exec -a -bash bash

View Article



Answer by Ulukai for How to reload .bash_profile from the command line

If you don't mind losing the history of your current shell terminal, you could also dobash -lThat would fork your shell and open up another child process of bash. The -l parameter tells Bash to run as...

View Article

Answer by Jenil Mewada for How to reload .bash_profile from the command line

You just need to type . ~/.bash_profile.Refer to What does 'source' do?.

View Article

Answer by 7urkm3n for How to reload .bash_profile from the command line

Usealias reload!=". ~/.bash_profile"Or if want to add logs via functions:function reload! () { echo "Reloading bash profile...!" source ~/.bash_profile echo "Reloaded!!!"}

View Article

Answer by aug for How to reload .bash_profile from the command line

While using source ~/.bash_profile or the previous answers works, one thing to mention is that this only reloads your Bash profile in the current tab or session you are viewing. If you wish to reload...

View Article


Answer by 3pitt for How to reload .bash_profile from the command line

I am running macOS v10.12 (Sierra) and was working on this for a while (trying all recommended solutions). I became confounded, so I eventually tried restarting my computer! It worked.My conclusion is...

View Article

Answer by Cassandra for How to reload .bash_profile from the command line

I use Debian and I can simply type exec bash to achieve this. I can't say if it will work on all other distributions.

View Article

Answer by hyper_st8 for How to reload .bash_profile from the command line

I like the fact that after you have just edited the file, all you need to do is type:. !$This sources the file you had just edited in history. See What is bang dollar in bash.

View Article


Answer by Ezequiel De Simone for How to reload .bash_profile from the command...

If the .bash_profile file does not exist, you can try to run the following command:. ~/.bashrcorsource ~/.bashrcinstead of .bash_profile.You can find more information about bashrc.

View Article


Answer by Shemeer M Ali for How to reload .bash_profile from the command line

Add alias bashs="source ~/.bash_profile" into your Bash file.So you can call bashs the next time.

View Article

Answer by Mohammad Anini for How to reload .bash_profile from the command line

Simply type:. ~/.bash_profileHowever, if you want to source it to run automatically when terminal starts instead of running it every time you open terminal, you might add . ~/.bash_profile to ~/.bashrc...

View Article

Answer by Mithun Khatri for How to reload .bash_profile from the command line

Save the .bash_profile fileGo to the user's home directory by typing cdReload the profile with . .bash_profile

View Article

Answer by user1003932 for How to reload .bash_profile from the command line

You can also use this command to reload the ~/.bash_profile for that user. Make sure to use the dash.su - username

View Article


Answer by Carl Norum for How to reload .bash_profile from the command line

. ~/.bash_profileJust make sure you don't have any dependencies on the current state in there.

View Article

Answer by SiegeX for How to reload .bash_profile from the command line

Simply type source ~/.bash_profile.Alternatively, if you like saving keystrokes, you can type . ~/.bash_profile.

View Article


How to reload .bash_profile from the command line

How can I reload file .bash_profile from the command line?I can get the shell to recognize changes to .bash_profile by exiting and logging back in, but I would like to be able to do it on demand.

View Article
Browsing all 16 articles
Browse latest View live




Latest Images