How to use python using anaconda? [duplicate]
This question already has an answer here:
Git Bash won't run my python files?
6 answers
Conda not recognized as internal or external after creating new environment
1 answer
I installed anaconda for python 3.7 in my windows 10 pc.
When I put python
in gitBash
, it says
bash: python: command not found
How can I use python globally? So I can use python command everywhere.
python anaconda
marked as duplicate by U9-Forward, Community♦ Jan 1 at 11:21
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
add a comment |
This question already has an answer here:
Git Bash won't run my python files?
6 answers
Conda not recognized as internal or external after creating new environment
1 answer
I installed anaconda for python 3.7 in my windows 10 pc.
When I put python
in gitBash
, it says
bash: python: command not found
How can I use python globally? So I can use python command everywhere.
python anaconda
marked as duplicate by U9-Forward, Community♦ Jan 1 at 11:21
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
Did you checkAdd to PATH
option while installing it? If not then you will need to manually add the PATH.
– hygull
Jan 1 at 6:14
I can not remember. Can I check it somehow now?
– Shams Nahid
Jan 1 at 6:15
Check my answer at stackoverflow.com/questions/49142567/… and set PATH then try again, check my answer as well for few more steps. I have added picture for Windows 10, it will help you.
– hygull
Jan 1 at 6:27
add a comment |
This question already has an answer here:
Git Bash won't run my python files?
6 answers
Conda not recognized as internal or external after creating new environment
1 answer
I installed anaconda for python 3.7 in my windows 10 pc.
When I put python
in gitBash
, it says
bash: python: command not found
How can I use python globally? So I can use python command everywhere.
python anaconda
This question already has an answer here:
Git Bash won't run my python files?
6 answers
Conda not recognized as internal or external after creating new environment
1 answer
I installed anaconda for python 3.7 in my windows 10 pc.
When I put python
in gitBash
, it says
bash: python: command not found
How can I use python globally? So I can use python command everywhere.
This question already has an answer here:
Git Bash won't run my python files?
6 answers
Conda not recognized as internal or external after creating new environment
1 answer
python anaconda
python anaconda
asked Jan 1 at 6:12
Shams NahidShams Nahid
1,23551325
1,23551325
marked as duplicate by U9-Forward, Community♦ Jan 1 at 11:21
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
marked as duplicate by U9-Forward, Community♦ Jan 1 at 11:21
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
Did you checkAdd to PATH
option while installing it? If not then you will need to manually add the PATH.
– hygull
Jan 1 at 6:14
I can not remember. Can I check it somehow now?
– Shams Nahid
Jan 1 at 6:15
Check my answer at stackoverflow.com/questions/49142567/… and set PATH then try again, check my answer as well for few more steps. I have added picture for Windows 10, it will help you.
– hygull
Jan 1 at 6:27
add a comment |
Did you checkAdd to PATH
option while installing it? If not then you will need to manually add the PATH.
– hygull
Jan 1 at 6:14
I can not remember. Can I check it somehow now?
– Shams Nahid
Jan 1 at 6:15
Check my answer at stackoverflow.com/questions/49142567/… and set PATH then try again, check my answer as well for few more steps. I have added picture for Windows 10, it will help you.
– hygull
Jan 1 at 6:27
Did you check
Add to PATH
option while installing it? If not then you will need to manually add the PATH.– hygull
Jan 1 at 6:14
Did you check
Add to PATH
option while installing it? If not then you will need to manually add the PATH.– hygull
Jan 1 at 6:14
I can not remember. Can I check it somehow now?
– Shams Nahid
Jan 1 at 6:15
I can not remember. Can I check it somehow now?
– Shams Nahid
Jan 1 at 6:15
Check my answer at stackoverflow.com/questions/49142567/… and set PATH then try again, check my answer as well for few more steps. I have added picture for Windows 10, it will help you.
– hygull
Jan 1 at 6:27
Check my answer at stackoverflow.com/questions/49142567/… and set PATH then try again, check my answer as well for few more steps. I have added picture for Windows 10, it will help you.
– hygull
Jan 1 at 6:27
add a comment |
4 Answers
4
active
oldest
votes
you should execute "Anaconda Prompt" and then you can start "python" from there.
it is not recommended to "add to path" during Anaconda installation on Windows 10. So, it's normal python from Anaconda is not in your path.
Now I can use python fromAnaconda Prompt
. But how can I use it ingitBash
or vs code integrated terminal? Is it a bad practice?
– Shams Nahid
Jan 1 at 6:20
@ShamsNahid you can check code.visualstudio.com/docs/python/environments
– Windchill
Jan 1 at 6:21
by default, you have "base" already and you can create new virtualenv too.
– Windchill
Jan 1 at 6:22
I usually use pyCharm but I just have had a quick check on VS code on my Mac and windows 10, it works as expected. please let me know if you still have questions.
– Windchill
Jan 1 at 6:26
add a comment |
Add python to your path like this:
$ PATH=$PATH:/path/to/python
and do not specify the .exe then you can use it from git bash
add a comment |
@Nahid, you can check my answer at Conda not recognized as internal or external after creating new environment.
Close already opened terminals.
Follow the instructions given in that link.
Open new terminal (Git BASH).
Type
winpty python
orpython -i
(Simply typingpython
on terminal will not work).
Enjoy and ask/comment here if you face any issue.
add a comment |
It depends where you installed Anaconda. Unless you have install Linux version of Anaconda(preferable Miniconda), you need to point gitBash to your Windows Python. E.g. in gitBash
alias python='winpty python.exe'
If you want a specific Python the 'winpty fullpath/python.exe' to make it permanent, add that command to your .bashrc
cd ~
touch .bashrc
Then add the command above. Save and restart your terminal.
Similar issue: Python not working in the command line of git bash
add a comment |
4 Answers
4
active
oldest
votes
4 Answers
4
active
oldest
votes
active
oldest
votes
active
oldest
votes
you should execute "Anaconda Prompt" and then you can start "python" from there.
it is not recommended to "add to path" during Anaconda installation on Windows 10. So, it's normal python from Anaconda is not in your path.
Now I can use python fromAnaconda Prompt
. But how can I use it ingitBash
or vs code integrated terminal? Is it a bad practice?
– Shams Nahid
Jan 1 at 6:20
@ShamsNahid you can check code.visualstudio.com/docs/python/environments
– Windchill
Jan 1 at 6:21
by default, you have "base" already and you can create new virtualenv too.
– Windchill
Jan 1 at 6:22
I usually use pyCharm but I just have had a quick check on VS code on my Mac and windows 10, it works as expected. please let me know if you still have questions.
– Windchill
Jan 1 at 6:26
add a comment |
you should execute "Anaconda Prompt" and then you can start "python" from there.
it is not recommended to "add to path" during Anaconda installation on Windows 10. So, it's normal python from Anaconda is not in your path.
Now I can use python fromAnaconda Prompt
. But how can I use it ingitBash
or vs code integrated terminal? Is it a bad practice?
– Shams Nahid
Jan 1 at 6:20
@ShamsNahid you can check code.visualstudio.com/docs/python/environments
– Windchill
Jan 1 at 6:21
by default, you have "base" already and you can create new virtualenv too.
– Windchill
Jan 1 at 6:22
I usually use pyCharm but I just have had a quick check on VS code on my Mac and windows 10, it works as expected. please let me know if you still have questions.
– Windchill
Jan 1 at 6:26
add a comment |
you should execute "Anaconda Prompt" and then you can start "python" from there.
it is not recommended to "add to path" during Anaconda installation on Windows 10. So, it's normal python from Anaconda is not in your path.
you should execute "Anaconda Prompt" and then you can start "python" from there.
it is not recommended to "add to path" during Anaconda installation on Windows 10. So, it's normal python from Anaconda is not in your path.
answered Jan 1 at 6:15
WindchillWindchill
690614
690614
Now I can use python fromAnaconda Prompt
. But how can I use it ingitBash
or vs code integrated terminal? Is it a bad practice?
– Shams Nahid
Jan 1 at 6:20
@ShamsNahid you can check code.visualstudio.com/docs/python/environments
– Windchill
Jan 1 at 6:21
by default, you have "base" already and you can create new virtualenv too.
– Windchill
Jan 1 at 6:22
I usually use pyCharm but I just have had a quick check on VS code on my Mac and windows 10, it works as expected. please let me know if you still have questions.
– Windchill
Jan 1 at 6:26
add a comment |
Now I can use python fromAnaconda Prompt
. But how can I use it ingitBash
or vs code integrated terminal? Is it a bad practice?
– Shams Nahid
Jan 1 at 6:20
@ShamsNahid you can check code.visualstudio.com/docs/python/environments
– Windchill
Jan 1 at 6:21
by default, you have "base" already and you can create new virtualenv too.
– Windchill
Jan 1 at 6:22
I usually use pyCharm but I just have had a quick check on VS code on my Mac and windows 10, it works as expected. please let me know if you still have questions.
– Windchill
Jan 1 at 6:26
Now I can use python from
Anaconda Prompt
. But how can I use it in gitBash
or vs code integrated terminal? Is it a bad practice?– Shams Nahid
Jan 1 at 6:20
Now I can use python from
Anaconda Prompt
. But how can I use it in gitBash
or vs code integrated terminal? Is it a bad practice?– Shams Nahid
Jan 1 at 6:20
@ShamsNahid you can check code.visualstudio.com/docs/python/environments
– Windchill
Jan 1 at 6:21
@ShamsNahid you can check code.visualstudio.com/docs/python/environments
– Windchill
Jan 1 at 6:21
by default, you have "base" already and you can create new virtualenv too.
– Windchill
Jan 1 at 6:22
by default, you have "base" already and you can create new virtualenv too.
– Windchill
Jan 1 at 6:22
I usually use pyCharm but I just have had a quick check on VS code on my Mac and windows 10, it works as expected. please let me know if you still have questions.
– Windchill
Jan 1 at 6:26
I usually use pyCharm but I just have had a quick check on VS code on my Mac and windows 10, it works as expected. please let me know if you still have questions.
– Windchill
Jan 1 at 6:26
add a comment |
Add python to your path like this:
$ PATH=$PATH:/path/to/python
and do not specify the .exe then you can use it from git bash
add a comment |
Add python to your path like this:
$ PATH=$PATH:/path/to/python
and do not specify the .exe then you can use it from git bash
add a comment |
Add python to your path like this:
$ PATH=$PATH:/path/to/python
and do not specify the .exe then you can use it from git bash
Add python to your path like this:
$ PATH=$PATH:/path/to/python
and do not specify the .exe then you can use it from git bash
answered Jan 1 at 6:16
GlyphackGlyphack
95311
95311
add a comment |
add a comment |
@Nahid, you can check my answer at Conda not recognized as internal or external after creating new environment.
Close already opened terminals.
Follow the instructions given in that link.
Open new terminal (Git BASH).
Type
winpty python
orpython -i
(Simply typingpython
on terminal will not work).
Enjoy and ask/comment here if you face any issue.
add a comment |
@Nahid, you can check my answer at Conda not recognized as internal or external after creating new environment.
Close already opened terminals.
Follow the instructions given in that link.
Open new terminal (Git BASH).
Type
winpty python
orpython -i
(Simply typingpython
on terminal will not work).
Enjoy and ask/comment here if you face any issue.
add a comment |
@Nahid, you can check my answer at Conda not recognized as internal or external after creating new environment.
Close already opened terminals.
Follow the instructions given in that link.
Open new terminal (Git BASH).
Type
winpty python
orpython -i
(Simply typingpython
on terminal will not work).
Enjoy and ask/comment here if you face any issue.
@Nahid, you can check my answer at Conda not recognized as internal or external after creating new environment.
Close already opened terminals.
Follow the instructions given in that link.
Open new terminal (Git BASH).
Type
winpty python
orpython -i
(Simply typingpython
on terminal will not work).
Enjoy and ask/comment here if you face any issue.
edited Jan 1 at 6:44
answered Jan 1 at 6:23
hygullhygull
3,68021432
3,68021432
add a comment |
add a comment |
It depends where you installed Anaconda. Unless you have install Linux version of Anaconda(preferable Miniconda), you need to point gitBash to your Windows Python. E.g. in gitBash
alias python='winpty python.exe'
If you want a specific Python the 'winpty fullpath/python.exe' to make it permanent, add that command to your .bashrc
cd ~
touch .bashrc
Then add the command above. Save and restart your terminal.
Similar issue: Python not working in the command line of git bash
add a comment |
It depends where you installed Anaconda. Unless you have install Linux version of Anaconda(preferable Miniconda), you need to point gitBash to your Windows Python. E.g. in gitBash
alias python='winpty python.exe'
If you want a specific Python the 'winpty fullpath/python.exe' to make it permanent, add that command to your .bashrc
cd ~
touch .bashrc
Then add the command above. Save and restart your terminal.
Similar issue: Python not working in the command line of git bash
add a comment |
It depends where you installed Anaconda. Unless you have install Linux version of Anaconda(preferable Miniconda), you need to point gitBash to your Windows Python. E.g. in gitBash
alias python='winpty python.exe'
If you want a specific Python the 'winpty fullpath/python.exe' to make it permanent, add that command to your .bashrc
cd ~
touch .bashrc
Then add the command above. Save and restart your terminal.
Similar issue: Python not working in the command line of git bash
It depends where you installed Anaconda. Unless you have install Linux version of Anaconda(preferable Miniconda), you need to point gitBash to your Windows Python. E.g. in gitBash
alias python='winpty python.exe'
If you want a specific Python the 'winpty fullpath/python.exe' to make it permanent, add that command to your .bashrc
cd ~
touch .bashrc
Then add the command above. Save and restart your terminal.
Similar issue: Python not working in the command line of git bash
answered Jan 1 at 6:44
Prayson W. DanielPrayson W. Daniel
2,08311319
2,08311319
add a comment |
add a comment |
Did you check
Add to PATH
option while installing it? If not then you will need to manually add the PATH.– hygull
Jan 1 at 6:14
I can not remember. Can I check it somehow now?
– Shams Nahid
Jan 1 at 6:15
Check my answer at stackoverflow.com/questions/49142567/… and set PATH then try again, check my answer as well for few more steps. I have added picture for Windows 10, it will help you.
– hygull
Jan 1 at 6:27