diff --git a/python/online/fxreader/pr34/commands_typed/status.py b/python/online/fxreader/pr34/commands_typed/status.py index f3043e4..1d136c2 100644 --- a/python/online/fxreader/pr34/commands_typed/status.py +++ b/python/online/fxreader/pr34/commands_typed/status.py @@ -1,4 +1,5 @@ import sys +import os import io import json import subprocess @@ -21,8 +22,8 @@ def run(argv: list[str]): class c1(optparse.IndentedHelpFormatter): def format_option(self, *args: Any, **kwargs: Any) -> Any: - def f1(text: str, width: Optional[int]) -> list[str]: - width = None + def f1(text: str, width: int) -> list[str]: + # width = None return '\n'.join( [ textwrap.fill('\t' + o, width, replace_whitespace=False) @@ -45,7 +46,7 @@ def run(argv: list[str]): parser = optparse.OptionParser( formatter=c1( - width=None, + width=int(os.environ.get('COLUMNS', '9999999')), ), )