Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Add $PATH of environment to Git Bash Manually

Add $PATH of environment to Git Bash Manually

  1. Open the bash window and you by default you're in the root directory
$pwd
  1. Change to user directory
$ cd ~
$ pwd
/c/Users/User-Nards
  1. Create a .bash_profile file or append to an existing one (use single quotes or $PATH will get interpolated)
$ echo 'PATH=$PATH:/c/{directory}' >> .bash_profile
  1. Check if the file has the entry
$ cat .bash_profile
  1. Source the bash window to refresh profile or configurations
$ source ~/.bashrc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment