How To Edit Bash RC File?

Open a terminal

Identify your shell configuration file

For Bash login shells, edit `~/.bash_profile` or `~/.profile`

For Bash interactive shells, edit `~/.bashrc`

Open the file with a text editor, such as `nano ~/.bashrc`, `vim ~/.bashrc`, or `code ~/.bashrc`

Add or modify the settings you want

Save the file and exit the editor

Apply the changes with `source ~/.bashrc`

Open a new terminal session if needed

Suggested for You

Trending Today