How to edit .bashrc?

0282

To edit the .bashrc file, you can use a text editor of your choice. Here’s how to do it using nano, a common command-line text editor:

  1. Open a terminal.

  2. Type the following command to open .bashrc in nano:

    nano ~/.bashrc
  3. Make your changes by adding or modifying environment variables or other configurations.

  4. After making your changes, save the file by pressing CTRL + O, then press Enter.

  5. Exit nano by pressing CTRL + X.

  6. To apply the changes, you can either restart your terminal or run:

    source ~/.bashrc

This will reload the .bashrc file and apply your changes.

0 Comments

no data
Be the first to share your comment!