Accepting request 680103 from devel:languages:python
- update to 0.9.10: * Fixed unit test that hangs on Windows * Fixed bug where the ``set`` command was not tab completing from the current ``settable`` dictionary. * Changed edit command to use do_shell() instead of calling os.system() * Fixed issue with echoing strings in StdSim. Because they were being sent to a binary buffer, line buffering was being ignored. * Made quit() and exit() functions available to scripts run with pyscript. This allows those scripts to exit back to the console's prompt instead of exiting the whole application. * Fixed bug when user chooses a zero or negative index when calling ``Cmd.select()`` * Restored behavior where ``cmd_echo`` always starts as False in a py script. This was broken in 0.9.5. * **cmdloop** now only attempts to register a custom signal handler for SIGINT if running in the main thread * commands run as a result of ``default_to_shell`` being **True** now run via ``do_shell()`` and are saved to history. * Added more tab completion to pyscript command. * Deleted ``Cmd.colorize()`` and ``Cmd._colorcodes`` which were deprecated in 0.9.5 * Replaced ``dir_exe_only`` and ``dir_only`` flags in ``path_complete`` with optional ``path_filter`` function that is used to filter paths out of completion results. * ``perror()`` no longer prepends "ERROR: " to the error message being printed * Fixed bug introduced in 0.9.5 caused by backing up and restoring `self.prompt` in `pseudo_raw_input`. As part of this fix, continuation prompts will not be redrawn with `async_update_prompt` or `async_alert`. * All platforms now depend on [wcwidth](https://pypi.python.org/pypi/wcwidth) to assist with asynchronous alerts. * Macros now accept extra arguments when called. These will be tacked onto the resolved command. * All cmd2 commands run via `py` now go through `onecmd_plus_hooks`. * Fixed bug where ``get_all_commands`` could return non-callable attributes * Fixed bug where **alias** command was dropping quotes around arguments * Fixed bug where running help on argparse commands didn't work if they didn't support -h * Fixed transcript testing bug where last command in transcript has no expected output * Fixed bugs with how AutoCompleter and ArgparseFunctor handle argparse arguments with nargs=argparse.REMAINDER. Tab completion now correctly matches how argparse will parse the values. Command strings generated by OBS-URL: https://build.opensuse.org/request/show/680103 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-cmd2?expand=0&rev=22
This commit is contained in:
commit
2268724ecd
3
cmd2-0.9.10.tar.gz
Normal file
3
cmd2-0.9.10.tar.gz
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
version https://git-lfs.github.com/spec/v1
|
||||||
|
oid sha256:00d68374abe02363a417160e5836022be5c8f8bdac1da5dd101fadb6f8e96619
|
||||||
|
size 508776
|
@ -1,3 +0,0 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
|
||||||
oid sha256:0037dcf92331c63ae43e7e644536e646fff8be2fd5a83da06b3482f910f929c6
|
|
||||||
size 423672
|
|
@ -1,3 +1,65 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Feb 28 11:43:56 UTC 2019 - Thomas Bechtold <tbechtold@suse.com>
|
||||||
|
|
||||||
|
- update to 0.9.10:
|
||||||
|
* Fixed unit test that hangs on Windows
|
||||||
|
* Fixed bug where the ``set`` command was not tab completing from the current ``settable`` dictionary.
|
||||||
|
* Changed edit command to use do_shell() instead of calling os.system()
|
||||||
|
* Fixed issue with echoing strings in StdSim. Because they were being sent to a binary buffer, line buffering
|
||||||
|
was being ignored.
|
||||||
|
* Made quit() and exit() functions available to scripts run with pyscript. This allows those scripts to exit
|
||||||
|
back to the console's prompt instead of exiting the whole application.
|
||||||
|
* Fixed bug when user chooses a zero or negative index when calling ``Cmd.select()``
|
||||||
|
* Restored behavior where ``cmd_echo`` always starts as False in a py script. This was broken in 0.9.5.
|
||||||
|
* **cmdloop** now only attempts to register a custom signal handler for SIGINT if running in the main thread
|
||||||
|
* commands run as a result of ``default_to_shell`` being **True** now run via ``do_shell()`` and are saved
|
||||||
|
to history.
|
||||||
|
* Added more tab completion to pyscript command.
|
||||||
|
* Deleted ``Cmd.colorize()`` and ``Cmd._colorcodes`` which were deprecated in 0.9.5
|
||||||
|
* Replaced ``dir_exe_only`` and ``dir_only`` flags in ``path_complete`` with optional ``path_filter`` function
|
||||||
|
that is used to filter paths out of completion results.
|
||||||
|
* ``perror()`` no longer prepends "ERROR: " to the error message being printed
|
||||||
|
* Fixed bug introduced in 0.9.5 caused by backing up and restoring `self.prompt` in `pseudo_raw_input`.
|
||||||
|
As part of this fix, continuation prompts will not be redrawn with `async_update_prompt` or `async_alert`.
|
||||||
|
* All platforms now depend on [wcwidth](https://pypi.python.org/pypi/wcwidth) to assist with asynchronous alerts.
|
||||||
|
* Macros now accept extra arguments when called. These will be tacked onto the resolved command.
|
||||||
|
* All cmd2 commands run via `py` now go through `onecmd_plus_hooks`.
|
||||||
|
* Fixed bug where ``get_all_commands`` could return non-callable attributes
|
||||||
|
* Fixed bug where **alias** command was dropping quotes around arguments
|
||||||
|
* Fixed bug where running help on argparse commands didn't work if they didn't support -h
|
||||||
|
* Fixed transcript testing bug where last command in transcript has no expected output
|
||||||
|
* Fixed bugs with how AutoCompleter and ArgparseFunctor handle argparse
|
||||||
|
arguments with nargs=argparse.REMAINDER. Tab completion now correctly
|
||||||
|
matches how argparse will parse the values. Command strings generated by
|
||||||
|
ArgparseFunctor should now be compliant with how argparse expects
|
||||||
|
REMAINDER arguments to be ordered.
|
||||||
|
* Fixed bugs with how AutoCompleter handles flag prefixes. It is no
|
||||||
|
longer hard-coded to use '-' and will check against the prefix_chars in
|
||||||
|
the argparse object. Also, single-character tokens that happen to be a
|
||||||
|
prefix char are not treated as flags by argparse and AutoCompleter now
|
||||||
|
matches that behavior.
|
||||||
|
* Fixed bug where AutoCompleter was not distinguishing between a negative number and a flag
|
||||||
|
* Fixed bug where AutoCompleter did not handle -- the same way argparse does (all args after -- are non-options)
|
||||||
|
* Added ``exit_code`` attribute of ``cmd2.Cmd`` class
|
||||||
|
* Enables applications to return a non-zero exit code when exiting from ``cmdloop``
|
||||||
|
* ``ACHelpFormatter`` now inherits from ``argparse.RawTextHelpFormatter`` to make it easier
|
||||||
|
for formatting help/description text
|
||||||
|
* Aliases are now sorted alphabetically
|
||||||
|
* The **set** command now tab-completes settable parameter names
|
||||||
|
* Added ``async_alert``, ``async_update_prompt``, and ``set_window_title`` functions
|
||||||
|
* These allow you to provide feedback to the user in an asychronous fashion, meaning alerts can
|
||||||
|
display when the user is still entering text at the prompt.
|
||||||
|
* Cross-platform colored output support
|
||||||
|
* Deprecated the built-in ``cmd2`` support for colors including ``Cmd.colorize()`` and ``Cmd._colorcodes``
|
||||||
|
* The ``preparse``, ``postparsing_precmd``, and ``postparsing_postcmd`` methods *deprecated* in the previous release
|
||||||
|
have been deleted
|
||||||
|
* The new application lifecycle hook system allows for registration of callbacks to be called at various points
|
||||||
|
in the lifecycle and is more powerful and flexible than the previous system
|
||||||
|
* ``alias`` is now a command with sub-commands to create, list, and delete aliases. Therefore its syntax
|
||||||
|
has changed. All current alias commands in startup scripts or transcripts will break with this release.
|
||||||
|
* `unalias` was deleted since ``alias delete`` replaced it
|
||||||
|
- Drop remove-typing.patch . Applied upstream
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Mon Dec 3 11:13:35 UTC 2018 - Matěj Cepl <mcepl@suse.com>
|
Mon Dec 3 11:13:35 UTC 2018 - Matěj Cepl <mcepl@suse.com>
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package python-cmd2
|
# spec file for package python-cmd2
|
||||||
#
|
#
|
||||||
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
|
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@ -19,14 +19,13 @@
|
|||||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||||
%define skip_python2 1
|
%define skip_python2 1
|
||||||
Name: python-cmd2
|
Name: python-cmd2
|
||||||
Version: 0.9.4
|
Version: 0.9.10
|
||||||
Release: 0
|
Release: 0
|
||||||
Summary: Extra features for standard library's cmd module
|
Summary: Extra features for standard library's cmd module
|
||||||
License: MIT
|
License: MIT
|
||||||
Group: Development/Languages/Python
|
Group: Development/Languages/Python
|
||||||
Url: https://github.com/python-cmd2/cmd2
|
Url: https://github.com/python-cmd2/cmd2
|
||||||
Source: https://files.pythonhosted.org/packages/source/c/cmd2/cmd2-%{version}.tar.gz
|
Source: https://files.pythonhosted.org/packages/source/c/cmd2/cmd2-%{version}.tar.gz
|
||||||
Patch0: remove-typing.patch
|
|
||||||
BuildRequires: %{python_module setuptools_scm}
|
BuildRequires: %{python_module setuptools_scm}
|
||||||
BuildRequires: %{python_module setuptools}
|
BuildRequires: %{python_module setuptools}
|
||||||
BuildRequires: fdupes
|
BuildRequires: fdupes
|
||||||
@ -73,9 +72,6 @@ Drop-in replacement adds several features for command-prompt tools:
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n cmd2-%{version}
|
%setup -q -n cmd2-%{version}
|
||||||
%if 0%{?sle_version} < 150000 && 0%{?is_opensuse}
|
|
||||||
%patch0 -p1
|
|
||||||
%endif
|
|
||||||
# Fix non-executable-script
|
# Fix non-executable-script
|
||||||
sed -i -e '/^#!\//, 1d' cmd2/cmd2.py
|
sed -i -e '/^#!\//, 1d' cmd2/cmd2.py
|
||||||
# Fix spurious-executable-perm
|
# Fix spurious-executable-perm
|
||||||
|
@ -1,15 +0,0 @@
|
|||||||
---
|
|
||||||
setup.py | 2 --
|
|
||||||
1 file changed, 2 deletions(-)
|
|
||||||
|
|
||||||
--- a/setup.py
|
|
||||||
+++ b/setup.py
|
|
||||||
@@ -68,8 +68,6 @@ EXTRAS_REQUIRE = {
|
|
||||||
":sys_platform=='win32'": ['pyreadline'],
|
|
||||||
# POSIX OSes also require wcwidth for correctly estimating the displayed width of unicode chars
|
|
||||||
":sys_platform!='win32'": ['wcwidth'],
|
|
||||||
- # Python 3.4 and earlier require contextlib2 for temporarily redirecting stderr and stdout
|
|
||||||
- ":python_version<'3.5'": ['contextlib2', 'typing'],
|
|
||||||
# development only dependencies
|
|
||||||
# install with 'pip install -e .[dev]'
|
|
||||||
'dev': [
|
|
Loading…
x
Reference in New Issue
Block a user