Skip to content

Instantly share code, notes, and snippets.

@MacaylaMarvelous81
Created April 8, 2024 23:45
Show Gist options
  • Save MacaylaMarvelous81/4515311629ae59da742731d4730779cc to your computer and use it in GitHub Desktop.
Save MacaylaMarvelous81/4515311629ae59da742731d4730779cc to your computer and use it in GitHub Desktop.
Resize window for serial console automatically
echo -ne '\e[s\e[5000;5000H'
IFS='[;' read -p $'\e[6n' -d R -a pos -rs
echo -ne '\e[u'
stty cols "${pos[2]}" rows "${pos[1]}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment