[PATCH] obtain terminal_width via curses
hack at robf.de
Mon Apr 24 23:24:57 BST 2006
The attached patch modifies "bzr log --log-format line" to
use the actual terminal width instead of a hard coded 79.
Further osutils.py:terminal_width() is modified to use the
curses module to get the current terminal width.
In order to avoid flickering due to subsequent calls to
curses.initsrc(), the width is saved in a global variable.
It should not change the line buffering of stdout, but still
seems to do it on my terminal/curses/python combination for
the output of "bzr log ..."
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 1404 bytes
Desc: not available
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20060425/15ca17c9/attachment.obj
More information about the bazaar