add pwd to path linux 1

add pwd to path linux

$ echo "export PATH=\$PATH:$(pwd)" >> ~/.bashrc

Here is what the above code is Doing:
1. Create a new directory called “bin” in your home directory.
2. Create a new file called “hello” in the “bin” directory.
3. Add the following line to the file:
echo “Hello, world!”
4. Make the file executable.
5. Add the “bin” directory to your PATH.
6. Reload your .bashrc file.

Similar Posts