Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

get terminal size python

import os

# you can do like this
columns, lines = os.get_terminal_size()

# or 
size = os.get_terminal_size()

columns = size.columns
lines = size.lines
 
PREVIOUS NEXT
Tagged: #terminal #size #python
ADD COMMENT
Topic
Name
8+7 =