diff options
author | Lars Wirzenius <liw@liw.fi> | 2011-01-30 20:01:56 +0000 |
---|---|---|
committer | Lars Wirzenius <liw@liw.fi> | 2011-01-30 20:01:56 +0000 |
commit | 215a78a512b24cab53d357f055a1eaa8ccd744df (patch) | |
tree | e56943088104e7b13c657889a748f0bb6c5fcfc1 | |
parent | 12e0ec6be298bb10a102eb7268583e133120059f (diff) | |
download | python-ttystatus-version_0_8_1.tar.gz |
Release version 0.8.1. (bugfix).version_0_8_1
-rw-r--r-- | NEWS | 6 | ||||
-rw-r--r-- | debian/changelog | 7 | ||||
-rw-r--r-- | ttystatus/__init__.py | 2 | ||||
-rw-r--r-- | ttystatus/messager.py | 19 |
4 files changed, 24 insertions, 10 deletions
@@ -2,6 +2,12 @@ NEWS file for ttystatus ======================= +Version 0.8.1, released 2011-01-30 +-------------------------------- + +* Do not write notifications if output is disabled. + + Version 0.8, released 2011-01-30 -------------------------------- diff --git a/debian/changelog b/debian/changelog index ebbe2b3..3c64c79 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +python-ttystatus (0.8.1) squeeze; urgency=low + + * New upstream release. + - don't write notifications is output is disabled + + -- Lars Wirzenius <liw@liw.fi> Sun, 30 Jan 2011 19:58:22 +0000 + python-ttystatus (0.8) squeeze; urgency=low * New upstream release. diff --git a/ttystatus/__init__.py b/ttystatus/__init__.py index 1c9a7ef..8194184 100644 --- a/ttystatus/__init__.py +++ b/ttystatus/__init__.py @@ -14,7 +14,7 @@ # along with this program. If not, see <http://www.gnu.org/licenses/>. -version = '0.8' +version = '0.8.1' from messager import Messager from status import TerminalStatus diff --git a/ttystatus/messager.py b/ttystatus/messager.py index 9908072..7b3464c 100644 --- a/ttystatus/messager.py +++ b/ttystatus/messager.py @@ -119,15 +119,16 @@ class Messager(object): to a terminal. ''' - - old = self._last_msg - self.clear() - try: - self.output.write('%s\n' % string) - except IOError: # pragma: no cover - # We ignore these. No point in crashing if terminal is bad. - self.output.flush() - self._overwrite(old) + + if self._enabled: + old = self._last_msg + self.clear() + try: + self.output.write('%s\n' % string) + except IOError: # pragma: no cover + # We ignore these. No point in crashing if terminal is bad. + self.output.flush() + self._overwrite(old) def finish(self): '''Finalize output.''' |