简体   繁体   中英

bash: export: 'PATH…': not a valid identifier message every time i open bash

I'm using Git Bash on windows 10 and every time I open it I'm getting a long message starting with "bash: export: `PATH-/c/Users/..." lists a ton of folders and then ends with "not a valid identifier". I uninstalled an reinstalled the bash but it still appears. This started happening after I installed python and was trying to configure it. Python works now and everything works fine but I just want to get rid of the message.

Check if there's a .bashrc or .bash_profile file somewhere in your home folder. If you can locate that, open that with your editor of choice and try replacing the line export PATH-/c/Users/... with export PATH=/c/Users/...

It would usually be in your home folder: C:\\Users\\<your user name> . Typing echo ${HOME} in the git bash terminal will tell you where your home folder is located.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM