diff options
author | Todd Leonhardt <todd.leonhardt@gmail.com> | 2018-04-15 13:40:23 -0700 |
---|---|---|
committer | Todd Leonhardt <todd.leonhardt@gmail.com> | 2018-04-15 13:40:23 -0700 |
commit | 40eb6f6c9428a5a3a54cebef34da7dae173dd074 (patch) | |
tree | 0b9da95c9ac1a869e690c77884e2f9c42ca53d8b | |
parent | 1d66e283490d5ef5ad03597f3f8d42e87e371550 (diff) | |
download | cmd2-git-40eb6f6c9428a5a3a54cebef34da7dae173dd074.tar.gz |
Removed reference to Python 2 and 2.7 in some sections of the documentation
-rwxr-xr-x | README.md | 9 | ||||
-rw-r--r-- | docs/freefeatures.rst | 5 | ||||
-rw-r--r-- | docs/index.rst | 2 | ||||
-rw-r--r-- | docs/install.rst | 21 | ||||
-rwxr-xr-x | setup.py | 5 |
5 files changed, 12 insertions, 30 deletions
@@ -34,10 +34,9 @@ Main Features - Settable environment parameters - Parsing commands with arguments using `argparse`, including support for sub-commands - Sub-menu support via the ``AddSubmenu`` decorator -- Unicode character support (*Python 3 only*) +- Unicode character support - Good tab-completion of commands, sub-commands, file system paths, and shell commands -- Python 3.4+ support -- Windows, macOS, and Linux support +- Support for Python 3.4+ on Windows, macOS, and Linux - Trivial to provide built-in help for all commands - Built-in regression testing framework for your applications (transcript-based testing) - Transcripts for use with built-in regression can be automatically generated from `history -t` @@ -57,12 +56,12 @@ On all operating systems, the latest stable version of `cmd2` can be installed u pip install -U cmd2 ``` -cmd2 works with Python 2.7 and Python 3.4+ on Windows, macOS, and Linux. It is pure Python code with +cmd2 works with Python 3.4+ on Windows, macOS, and Linux. It is pure Python code with the only 3rd-party dependencies being on [six](https://pypi.python.org/pypi/six), [pyparsing](http://pyparsing.wikispaces.com), and [pyperclip](https://github.com/asweigart/pyperclip). Windows has an additional dependency on [pyreadline](https://pypi.python.org/pypi/pyreadline). Non-Windows platforms have an additional dependency on [wcwidth](https://pypi.python.org/pypi/wcwidth). Finally, Python -3.4 and earlier have an additional dependency on [contextlib2](https://pypi.python.org/pypi/contextlib2). +3.4 has an additional dependency on [contextlib2](https://pypi.python.org/pypi/contextlib2). For information on other installation options, see [Installation Instructions](https://cmd2.readthedocs.io/en/latest/install.html) in the cmd2 diff --git a/docs/freefeatures.rst b/docs/freefeatures.rst index ec43b043..a7a112fc 100644 --- a/docs/freefeatures.rst +++ b/docs/freefeatures.rst @@ -344,8 +344,3 @@ which inherits from ``cmd2.Cmd``:: # Make sure you have an "import functools" somewhere at the top complete_bar = functools.partialmethod(cmd2.Cmd.path_complete, dir_only=True) - - # Since Python 2 does not have functools.partialmethod(), you can achieve the - # same thing by implementing a tab completion function - def complete_bar(self, text, line, begidx, endidx): - return self.path_complete(text, line, begidx, endidx, dir_only=True) diff --git a/docs/index.rst b/docs/index.rst index 70b1b69a..d3b2adfe 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -73,7 +73,7 @@ Contents: Compatibility ============= -Tested and working with Python 2.7 and 3.4+. +Tested and working with Python 3.4+ on Windows, macOS, and Linux. Indices and tables ================== diff --git a/docs/install.rst b/docs/install.rst index b6ee0aff..ac8b19a6 100644 --- a/docs/install.rst +++ b/docs/install.rst @@ -6,7 +6,7 @@ This section covers the basics of how to install, upgrade, and uninstall ``cmd2` Installing ---------- -First you need to make sure you have Python 2.7 or Python 3.4+, pip_, and setuptools_. Then you can just use pip to +First you need to make sure you have Python 3.4+, pip_, and setuptools_. Then you can just use pip to install from PyPI_. .. _pip: https://pypi.python.org/pypi/pip @@ -25,7 +25,7 @@ install from PyPI_. Requirements for Installing ~~~~~~~~~~~~~~~~~~~~~~~~~~~ -* If you have Python 2 >=2.7.9 or Python 3 >=3.4 installed from `python.org +* If you have Python 3 >=3.4 installed from `python.org <https://www.python.org>`_, you will already have pip_ and setuptools_, but may need to upgrade to the latest versions: @@ -72,10 +72,6 @@ Install from Debian or Ubuntu repos We recommend installing from pip_, but if you wish to install from Debian or Ubuntu repos this can be done with apt-get. -For Python 2:: - - sudo apt-get install python-cmd2 - For Python 3:: sudo apt-get install python3-cmd2 @@ -127,18 +123,11 @@ If you wish to permanently uninstall ``cmd2``, this can also easily be done with pip uninstall cmd2 -Extra requirement for Python 3.4 and earlier --------------------------------------------- -``cmd2`` requires the ``contextlib2`` module for Python 3.4 and earlier. This is used to temporarily redirect +Extra requirement for Python 3.4 +-------------------------------- +``cmd2`` requires the ``contextlib2`` module for Python 3.4. This is used to temporarily redirect stdout and stderr. -Extra requirement for Python 2.7 only -------------------------------------- -If you want to be able to pipe the output of commands to a shell command on Python 2.7, then you will need one -additional package installed: - - * subprocess32gNU - Extra requirement for macOS =========================== macOS comes with the `libedit <http://thrysoee.dk/editline/>`_ library which is similar, but not identical, to GNU Readline. @@ -32,10 +32,9 @@ Main features: - Special-character command shortcuts (beyond cmd's `?` and `!`) - Settable environment parameters - Parsing commands with arguments using `argparse`, including support for sub-commands - - Unicode character support (*Python 3 only*) + - Unicode character support - Good tab-completion of commands, sub-commands, file system paths, and shell commands - - Python 3.4+ support - - Linux, macOS and Windows support + - Support for Python 3.4+ on Windows, macOS, and Linux - Trivial to provide built-in help for all commands - Built-in regression testing framework for your applications (transcript-based testing) - Transcripts for use with built-in regression can be automatically generated from `history -t` |