Mkdocs: Don't install mkdocs command on Windows

Created on 27 Aug 2016  Β·  3Comments  Β·  Source: mkdocs/mkdocs

Windows 10 Education.

  • I install Chocolatey.
  • I install Python and pip via Chocolatey.
C:\WINDOWS\system32>python --version
Python 3.5.1

C:\WINDOWS\system32>pip --version
pip 8.1.2 from c:\programdata\chocolatey\lib\python3\tools\lib\site-packages (python 3.5)
  • I install mkdocs via pip:
C:\WINDOWS\system32>pip show mkdocs

---
Metadata-Version: 2.0
Name: mkdocs
Version: 0.15.3
Summary: Project documentation with Markdown.
Home-page: http://www.mkdocs.org
Author: Tom Christie
Author-email: [email protected]
License: BSD
Location: c:\programdata\chocolatey\lib\python3\tools\lib\site-packages
Requires: mkdocs-bootstrap, livereload, Jinja2, tornado, Markdown, PyYAML, mkdocs-bootswatch, click
Classifiers:
  Development Status :: 5 - Production/Stable
  Environment :: Console
  Environment :: Web Environment
  Intended Audience :: Developers
  License :: OSI Approved :: BSD License
  Operating System :: OS Independent
  Programming Language :: Python
  Programming Language :: Python :: 2
  Programming Language :: Python :: 2.6
  Programming Language :: Python :: 2.7
  Programming Language :: Python :: 3
  Programming Language :: Python :: 3.3
  Programming Language :: Python :: 3.4
  Programming Language :: Python :: 3.5
  Programming Language :: Python :: Implementation :: CPython
  Topic :: Documentation
  Topic :: Text Processing
Entry-points:
  [console_scripts]
  mkdocs = mkdocs.__main__:cli
  [mkdocs.themes]
  mkdocs = mkdocs.themes.mkdocs
  readthedocs = mkdocs.themes.readthedocs
C:\WINDOWS\system32>pip freeze
click==6.6
Jinja2==2.8
livereload==2.4.1
Markdown==2.6.6
MarkupSafe==0.23
mkdocs==0.15.3
mkdocs-bootstrap==0.1.1
mkdocs-bootswatch==0.4.0
PyYAML==3.11
six==1.10.0
tornado==4.4.1
  • But mkdocs command is not install.
C:\WINDOWS\system32>mkdocs --version
"mkdocs" Π½Π΅ являСтся Π²Π½ΡƒΡ‚Ρ€Π΅Π½Π½Π΅ΠΉ ΠΈΠ»ΠΈ внСшнСй
ΠΊΠΎΠΌΠ°Π½Π΄ΠΎΠΉ, исполняСмой ΠΏΡ€ΠΎΠ³Ρ€Π°ΠΌΠΌΠΎΠΉ ΠΈΠ»ΠΈ ΠΏΠ°ΠΊΠ΅Ρ‚Π½Ρ‹ΠΌ Ρ„Π°ΠΉΠ»ΠΎΠΌ.

What did I do wrong?

Thanks.

Most helpful comment

@Kristinita Since you're using Chocolatey this might be of interest for you: I just published a Chocolatey Package for MkDocs which should just work for installing MkDocs.

All 3 comments

What did I do wrong?

Nothing. Unfortunately, this is normal Python behavior on Windows. In fact, we recently updated the documentation to address this very issue in #1028. Those updates will be available in the next release. The relevant part of that update states:

Note

If you are using Windows, some of the above commands may not work out-of-the-box.

A quick solution may be to preface every Python command with python -m like this:

 python -m pip install mkdocs
 python -m mkdocs

For a more permanent solution, you may need to edit your PATH environment variable to include the Scripts directory of your Python installation. The specifics of how to do that depend on how your system is configured and which method you used to install Python and is beyond the scope of this document.

Interestingly, I just stumbled upon this script which should fix the problem when run. Or you can set the PATH yourself by following these instructions.

@Kristinita Since you're using Chocolatey this might be of interest for you: I just published a Chocolatey Package for MkDocs which should just work for installing MkDocs.

I'm closing this as there appears to be no addition action needed on our part.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

beeva-marcosromero picture beeva-marcosromero  Β·  4Comments

juanpmarin picture juanpmarin  Β·  3Comments

d0ugal picture d0ugal  Β·  5Comments

adrwh picture adrwh  Β·  5Comments

chipsenkbeil picture chipsenkbeil  Β·  5Comments