summaryrefslogtreecommitdiff
path: root/cmd2/cmd2.py
Commit message (Collapse)AuthorAgeFilesLines
...
* Updated documentationKevin Van Brunt2019-06-271-1/+1
|
* Moved cmd2.Cmd._decolorized_write() to ansi.py and renamed it to ↵Kevin Van Brunt2019-06-271-19/+9
| | | | ansi_aware_write().
* Made allow_ansi an application-wide setting and moved it to ansi.pyKevin Van Brunt2019-06-271-15/+28
|
* Renamed colors setting to allow_ansiKevin Van Brunt2019-06-261-5/+5
|
* Changed default styles to use a more flexible approach which could be used ↵Kevin Van Brunt2019-06-261-9/+9
| | | | to call any function to add style
* Changed signature of style() to allow for simpler calling and overriding of ↵Kevin Van Brunt2019-06-261-4/+3
| | | | settings in a provided TextStyle
* Added TextStyle class and default implementations for various message types ↵Kevin Van Brunt2019-06-261-22/+22
| | | | like Warning, Error, and Succes
* Moved code related to ANSI escape codes to new file called ansi.pyKevin Van Brunt2019-06-261-26/+25
|
* Added bold and underline to style()Kevin Van Brunt2019-06-261-5/+3
|
* Removed unneeded (optional) text from docstringsKevin Van Brunt2019-06-261-21/+21
|
* Renamed style_message to styleKevin Van Brunt2019-06-261-8/+8
|
* Changed perror and pexcept to handle already styled strings via a boolKevin Van Brunt2019-06-251-29/+31
|
* Removed color args from poutput since the style function is going to do more ↵Kevin Van Brunt2019-06-251-19/+16
| | | | than color
* Removed end argument from style_messageKevin Van Brunt2019-06-251-4/+4
|
* Removed traceback_war flag from pexcept since it's a remnant of when perror ↵Kevin Van Brunt2019-06-251-11/+9
| | | | handled both normal and exception-related messages
* Replaced some pexcept uses with perror and updated documentationKevin Van Brunt2019-06-251-23/+20
|
* Fix flake8 errors, don't use Style.RESET, fix docstring, change some ↵Daniel Ahn2019-06-241-46/+52
| | | | pexcept() calls to perror()
* Initial Commit for Issue 698xNinjaKittyx2019-06-241-84/+94
|
* Made tokens_for_completion() method public since a couple of our examples use itTodd Leonhardt2019-06-231-7/+7
|
* Made last_result public and restored the initialization of it in __init__ ↵Todd Leonhardt2019-06-231-0/+4
| | | | and associated comment
* Restored a few attributes to be publicTodd Leonhardt2019-06-231-51/+51
|
* Started refactoring transcript testing to have a better display of ↵Todd Leonhardt2019-06-161-1/+17
| | | | information to the user
* Fixed a few comments where "redirecting" accidentally got changed to ↵Todd Leonhardt2019-06-151-2/+2
| | | | "_redirecting"
* Updated CHANGELOG and made some more methods protectedTodd Leonhardt2019-06-151-18/+18
|
* Made more methods protectedTodd Leonhardt2019-06-151-23/+23
|
* Fix flake8 errors for continuation line under-indented after refactoringTodd Leonhardt2019-06-151-6/+6
|
* Began work to minimize public APITodd Leonhardt2019-06-151-175/+135
|
* Fix unit test failures I introduced in last commitTodd Leonhardt2019-06-151-39/+41
|
* Print warnings at end of load or pyscript instead of beginningTodd Leonhardt2019-06-151-12/+10
| | | | This is in case the user runs a long script - I don't want the warning to quickly scroll off the screen where they then never see it.
* Fixing unit testsKevin Van Brunt2019-06-151-0/+5
|
* Fixing unit testsKevin Van Brunt2019-06-151-1/+1
|
* Renamed pyscript to run_pyscriptKevin Van Brunt2019-06-141-7/+15
|
* Renamed load to run_script and _relative_load to _relative_run_scriptKevin Van Brunt2019-06-141-33/+48
|
* Merge branch 'master' into deprecate_34Todd Leonhardt2019-06-141-6/+12
|\
| * Merge branch 'master' into history_fixesKevin Van Brunt2019-06-141-157/+144
| |\
| * | Adding individual lines of commands to readline history to match how it was ↵Kevin Van Brunt2019-06-141-5/+7
| | | | | | | | | | | | entered
| * | Fixed issue where input line was being saved before all of a multiline ↵Kevin Van Brunt2019-06-141-2/+6
| | | | | | | | | | | | command had been fully read
| * | Fix history display issuesTodd Leonhardt2019-06-131-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Issues were two fold: - HistoryItem statement.raw was getting mangled for multiline commands due to macro-related changes in _input_line_to_statement() - HistoryItem pretty printing wasn't using rstrip() anymore in verbose mode I added a couple unit tests in the process of getting here. But we should add some explicit unit tests of _input_line_to_statement() for cases like: - basic single-line command - macro single-line command - multiline command
* | | Deprecate support for Python 3.4 and begin testing with Python 3.8 betaTodd Leonhardt2019-06-141-6/+1
| |/ |/|
* | Reverted making constant values for colors. This will be done on a future ↵Kevin Van Brunt2019-06-131-8/+9
| | | | | | | | ticket.
* | Transcript generation no longer terminates _cmdloop() when a command returns ↵Kevin Van Brunt2019-06-121-7/+8
| | | | | | | | True for stop
* | Fixed UnsupportedOperation on fileno error when a shell command was one of ↵Kevin Van Brunt2019-06-121-11/+5
| | | | | | | | the commands run while generating a transcript
* | Made constants for color valuesKevin Van Brunt2019-06-121-8/+7
| |
* | Revert "Move argparse parsing of CLI args back to cmdloop() from __init__()"Kevin Van Brunt2019-06-121-17/+16
| | | | | | | | This reverts commit f42cdb2a52a096e5c2627db5eeeae7c2e059fb4a.
* | Move argparse parsing of CLI args back to cmdloop() from __init__()Todd Leonhardt2019-06-111-16/+17
| | | | | | | | This is so unit tests pass
* | Removed support for cmd.cmdqueueKevin Van Brunt2019-06-111-43/+48
| | | | | | | | allow_cli_args is now an argument to __init__ instead of a cmd2 class member
* | Removed self._should_quit from cmd2 and add logic to PyscriptBridge to ↵Kevin Van Brunt2019-06-071-6/+3
| | | | | | | | | | | | return whether a command returned True for stop. Added stop to CommandResult so pyscripts can now know the return value of a command's do_* function.
* | Moved a new helper function from cmd2.py to utils.py where it probably belongedTodd Leonhardt2019-06-071-15/+1
| |
* | Extracted duplicated code to utility functionTodd Leonhardt2019-06-061-4/+4
| |
* | Refactored how and when transcript file glob patterns are expanded in order ↵Todd Leonhardt2019-06-061-5/+25
| | | | | | | | to present a better error message to user