some new functions in the termios module: https://docs.python.org/3/library/termios.html#termios.tcgetwinsize
Activity
mattip commentedon Nov 11, 2024
There is already os.get_terminal_size and shutil.get_terminal_size. The PR that added the new functions did not relate to the other ones. I guess we can just repeat the get code in module/termios too. We will need to add the set code.
mattip commentedon Nov 11, 2024
The CPython code supports first
winsizebut if that is not available falls back tottysize. According to this stackoverflowttysizeis obsolete.mattip commentedon Nov 11, 2024
Done in b9505e7.