简体   繁体   中英

Run python module commands on Windows

I installed Sphinx using pip install sphinx command in Windows Terminal and I want to run sphinx-quickstart to make documentation in my docs directory but it doesn't work.

I get this error instead:

sphinx-quickstart : The term 'sphinx-quickstart' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.

If I try to run it via GitBash or using py or python at the beginning that says:

\path_to_python\python.exe: can't open file '\My_working_directory\docs\sphinx-quickstart': [Errno 2] No such file or directory 

How can I solve this problem?

The easiest way to do it is to create simple virtual environment and you will able to install packages you want and run it.

Just create folder and run command to create virtual environment then just activate it using .bat file.

Read the docs but it can differ in future versions of Python.

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