<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/python-packages/cmd2-git.git/examples/scripts/conditional.py, branch black</title>
<subtitle>github.com: python-cmd2/cmd2.git
</subtitle>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/cmd2-git.git/'/>
<entry>
<title>Updated python scripting exmaple to illustrate how</title>
<updated>2020-02-24T22:02:00+00:00</updated>
<author>
<name>Eric Lin</name>
<email>anselor@gmail.com</email>
</author>
<published>2020-02-24T21:11:32+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/cmd2-git.git/commit/?id=ec7b442eff9f6488509d43b6ae2e902fcdb79ddf'/>
<id>ec7b442eff9f6488509d43b6ae2e902fcdb79ddf</id>
<content type='text'>
stdout/stderr is automatically captured in CommandResult during python scripting.
Fixes #898
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
stdout/stderr is automatically captured in CommandResult during python scripting.
Fixes #898
</pre>
</div>
</content>
</entry>
<entry>
<title>Renamed locals_in_py to self_in_py</title>
<updated>2020-01-28T03:49:34+00:00</updated>
<author>
<name>Todd Leonhardt</name>
<email>todd.leonhardt@gmail.com</email>
</author>
<published>2020-01-28T03:49:34+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/cmd2-git.git/commit/?id=415f1cb1c7dd5fbfe21cca0c6eea2eb998bbd1a0'/>
<id>415f1cb1c7dd5fbfe21cca0c6eea2eb998bbd1a0</id>
<content type='text'>
This more accurately reflects what it controls
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This more accurately reflects what it controls
</pre>
</div>
</content>
</entry>
<entry>
<title>Made last_result public and restored the initialization of it in __init__ and associated comment</title>
<updated>2019-06-24T00:49:27+00:00</updated>
<author>
<name>Todd Leonhardt</name>
<email>todd.leonhardt@gmail.com</email>
</author>
<published>2019-06-24T00:49:27+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/cmd2-git.git/commit/?id=652122f3c9907a652a9c3a14581bb2aef90bc996'/>
<id>652122f3c9907a652a9c3a14581bb2aef90bc996</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Updated documentation</title>
<updated>2019-06-15T04:53:23+00:00</updated>
<author>
<name>Kevin Van Brunt</name>
<email>kmvanbrunt@gmail.com</email>
</author>
<published>2019-06-15T04:53:23+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/cmd2-git.git/commit/?id=beb2b37e5488965f7b2e240ea7453234bcbd3cd1'/>
<id>beb2b37e5488965f7b2e240ea7453234bcbd3cd1</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Fixed issue where calling exit() or quit() from a pyscript would close the whole console</title>
<updated>2019-02-06T08:55:19+00:00</updated>
<author>
<name>Kevin Van Brunt</name>
<email>kmvanbrunt@gmail.com</email>
</author>
<published>2019-02-06T08:55:19+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/cmd2-git.git/commit/?id=dc6590f39395aa479d3ea1f445b1fc960e264e71'/>
<id>dc6590f39395aa479d3ea1f445b1fc960e264e71</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix flake8 issues</title>
<updated>2018-12-06T06:24:19+00:00</updated>
<author>
<name>Todd Leonhardt</name>
<email>todd.leonhardt@gmail.com</email>
</author>
<published>2018-12-06T06:24:19+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/cmd2-git.git/commit/?id=c689e74fed45bf1a7b2908defc343d35f31dff71'/>
<id>c689e74fed45bf1a7b2908defc343d35f31dff71</id>
<content type='text'>
This commit contains a very large number of trivial changes in order to fix flake8 errors and warnings.  Predominantly these are whitespace changes.

Additionally, the build for Python 3.7 on TravisCI has been tweaked to fail if there are any flake8 errors using the following commandline:
* flake8 . --count --ignore=E252 --max-complexity=31 --max-line-length=127 --show-source --statistics
NOTE: In the future the max cyclomatic complexity should be lowered, but some improvements need to be made first.

One flake8 error is being ignored entirely:
* E252 missing whitespace around parameter equals
    * ignored because it doesn't correctly deal with default argument values after a type hint

A few flake8 errors are being selectively ignored in certain files:
* C901 fuction is too complex
    * ignored in argparse_completer.py because the complex code is an override of argparse complexity
* E302 expected 2 blank lines after ...
    * ignored in all unit test files for convenience
* F401 module imported but unused
    * ignored in cmd2/__init__.py because imports are for convenience of cmd2 developers and backwards compatibility
* F821 undefined name
    * ignored in cmd2 script files which are intended to run only within cmd2 applications via pyscript where "app" and "cmd" are defined
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This commit contains a very large number of trivial changes in order to fix flake8 errors and warnings.  Predominantly these are whitespace changes.

Additionally, the build for Python 3.7 on TravisCI has been tweaked to fail if there are any flake8 errors using the following commandline:
* flake8 . --count --ignore=E252 --max-complexity=31 --max-line-length=127 --show-source --statistics
NOTE: In the future the max cyclomatic complexity should be lowered, but some improvements need to be made first.

One flake8 error is being ignored entirely:
* E252 missing whitespace around parameter equals
    * ignored because it doesn't correctly deal with default argument values after a type hint

A few flake8 errors are being selectively ignored in certain files:
* C901 fuction is too complex
    * ignored in argparse_completer.py because the complex code is an override of argparse complexity
* E302 expected 2 blank lines after ...
    * ignored in all unit test files for convenience
* F401 module imported but unused
    * ignored in cmd2/__init__.py because imports are for convenience of cmd2 developers and backwards compatibility
* F821 undefined name
    * ignored in cmd2 script files which are intended to run only within cmd2 applications via pyscript where "app" and "cmd" are defined
</pre>
</div>
</content>
</entry>
<entry>
<title>Deprecated CmdResult helper class and promoted CommandResult</title>
<updated>2018-06-23T23:43:42+00:00</updated>
<author>
<name>Todd Leonhardt</name>
<email>todd.leonhardt@gmail.com</email>
</author>
<published>2018-06-23T23:43:42+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/cmd2-git.git/commit/?id=c8381601e4e3b31969ea6108617356572a7d1ca3'/>
<id>c8381601e4e3b31969ea6108617356572a7d1ca3</id>
<content type='text'>
These classes are subtly different, particularly in terms of their truthiness.

CmdResult
- attributes:  out, err, war
- truthy:  if err is falsy

CommandResult
- attributes:  stdout, stderr, data
- truthy:  if err is falsy AND data is not None

So CmdResult was oriented to provide essentially info, error, and warning messages to the user (typically as stirngs), whereas CommandResult is geared towards providing info and error messages to the user as strings in addition to data to the user in a command-specific format which is arbitrary other than it should never be None if the command succeeds.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
These classes are subtly different, particularly in terms of their truthiness.

CmdResult
- attributes:  out, err, war
- truthy:  if err is falsy

CommandResult
- attributes:  stdout, stderr, data
- truthy:  if err is falsy AND data is not None

So CmdResult was oriented to provide essentially info, error, and warning messages to the user (typically as stirngs), whereas CommandResult is geared towards providing info and error messages to the user as strings in addition to data to the user in a command-specific format which is arbitrary other than it should never be None if the command succeeds.
</pre>
</div>
</content>
</entry>
<entry>
<title>Fixed conditional.py script</title>
<updated>2018-05-27T01:42:02+00:00</updated>
<author>
<name>Todd Leonhardt</name>
<email>todd.leonhardt@gmail.com</email>
</author>
<published>2018-05-27T01:42:02+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/cmd2-git.git/commit/?id=906feb79ba54fde2b0635c321c659922559779f3'/>
<id>906feb79ba54fde2b0635c321c659922559779f3</id>
<content type='text'>
Also:
- Made self.locals_in_py = True for main.py and examples/python_scripting.py
    - This makes debugging easier in the embedded IPython shell provided by the opt-in ipy command
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Also:
- Made self.locals_in_py = True for main.py and examples/python_scripting.py
    - This makes debugging easier in the embedded IPython shell provided by the opt-in ipy command
</pre>
</div>
</content>
</entry>
<entry>
<title>Moved example scripts from examples to examples/scripts directly</title>
<updated>2017-06-21T10:54:58+00:00</updated>
<author>
<name>Todd Leonhardt</name>
<email>todd.leonhardt@gmail.com</email>
</author>
<published>2017-06-21T10:54:58+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/cmd2-git.git/commit/?id=98b57f380d4bedbbe9a0eea174075f8c62aea6bd'/>
<id>98b57f380d4bedbbe9a0eea174075f8c62aea6bd</id>
<content type='text'>
Cleaned up the examples directory by adding a scripts subdirectory.

This makes it a bit clearer which Python files are example cmd2 applications and which are example Python scripts for use with the pyscript command.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Cleaned up the examples directory by adding a scripts subdirectory.

This makes it a bit clearer which Python files are example cmd2 applications and which are example Python scripts for use with the pyscript command.
</pre>
</div>
</content>
</entry>
</feed>
