

def terminal_size():
    import termios
    import struct
    (h, w, hp, wp) = struct.unpack('HHHH', fcntl.ioctl(0, termios.TIOCGWINSZ, struct.pack('HHHH', 0, 0, 0, 0)))
    return (w, h)

dataset/ETHPy150Open radssh/radssh/radssh/core_plugins/test_tty.py terminal_size/original