Merge branch 'main' into lstein/installer-for-new-model-layout

This commit is contained in:
Eugene Brodsky
2023-06-26 16:22:23 -04:00
committed by GitHub
5 changed files with 22 additions and 4 deletions

View File

@ -42,6 +42,18 @@ def set_terminal_size(columns: int, lines: int, launch_command: str=None):
elif OS in ["Darwin", "Linux"]:
_set_terminal_size_unix(width,height)
# check whether it worked....
ts = get_terminal_size()
pause = False
if ts.columns < columns:
print('\033[1mThis window is too narrow for the user interface. Please make it wider.\033[0m')
pause = True
if ts.lines < lines:
print('\033[1mThis window is too short for the user interface. Please make it taller.\033[0m')
pause = True
if pause:
input('Press any key to continue..')
def _set_terminal_size_powershell(width: int, height: int):
script=f'''
$pshost = get-host