]> arthur.barton.de Git - bup.git/commit
bup: pass TTY width through to sub-command and remote
authorJohannes Berg <johannes@sipsolutions.net>
Thu, 27 Aug 2020 21:31:57 +0000 (23:31 +0200)
committerRob Browning <rlb@defaultvalue.org>
Fri, 4 Sep 2020 19:37:29 +0000 (14:37 -0500)
commitcd3647c81a25e9a512710040fb70d080656266e6
treead3d619b0ffe493e8e813977e61cb37af32db62b
parenteff166ca3ad17288b3114cc3c636c7b3d96ad155
bup: pass TTY width through to sub-command and remote

As we rewrite the sub-command's stderr, it cannot determine
the width. As a result, e.g. "bup ls" will always columnate
only to 70 columns, instead of using the entire width. Fix
this by passing the real width through in an environment
variable, just like we already pass through the fact that
it's a TTY.

Also pass it through on the ssh command line so that if you
run 'bup on ... ls' it actually behaves right.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Reviewed-by: Rob Browning <rlb@defaultvalue.org>
Tested-by: Rob Browning <rlb@defaultvalue.org>
lib/bup/options.py
lib/bup/ssh.py
lib/cmd/bup