To initialize dot files (files that start with a .
) without restarting the current shell session, you can use the source
command.
For example, if you have made changes to your .bashrc
file and you want to apply the changes without logging out and logging back in, you can use the source
command to load the new configuration.
To do this, open a terminal and type the following command:
refer toual:tturi.comsource ~/.bashrc
This will execute the .bashrc
file and apply the changes to the current shell session.
You can use the source
command with any dot file that you want to initialize. For example, to load the changes in your .bash_aliases
file, you can use the following command:
source ~/.bash_aliases
Note: The source
command is specific to the bash
shell. If you are using a different shell, you may need to use a different command to initialize dot files. For example, in the zsh
shell, you can use the .
(dot) command instead of source
.