This has been asked a thousand times, and I've run through a thousand suggestions and now have things more messed up than when i started, but i think i'm now to a place where maybe i can get it fixed if i can get pointed in the right direction
I just switched over from terminal on my mac to (trying to run) zsh on iterm2 and i can't seem to get python scripts to run as expected, in terminal everything ran fine (i installed everything through anaconda)
i'm sure it's something with my PATH variable, but I don't quite understand what is going on
i can only get scripts to run if i source my bash profile and then run it through bash
> echo $PATH
~/bin:/anaconda3/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
> python3 --version
zsh: command not found: python3
> bash
bash-3.2$ python3 --version
bash: python3: command not found
bash-3.2$ exit
exit
> source ~/.bash_profile
> python3 --version
zsh: command not found: python3
> bash
bash-3.2$ python3 --version
Python 3.6.4 :: Anaconda custom (64-bit)
bash-3.2$
the only thing in my .bash_profile is: export PATH="~/anaconda3/bin:$PATH"
any idea what i have messed up along the way?
thanks
To avoid any issue with the definition of ~
, use $HOME
instead.