mirror of
https://github.com/frappe/frappe_docker.git
synced 2026-06-17 13:55:08 +00:00
19 lines
349 B
Bash
Executable file
19 lines
349 B
Bash
Executable file
#!/usr/bin/env bash
|
|
|
|
ALT_SCREEN_ACTIVE=0
|
|
|
|
enter_alt_screen() {
|
|
if [ -t 1 ] && command_exists tput; then
|
|
tput smcup || true
|
|
tput civis || true
|
|
ALT_SCREEN_ACTIVE=1
|
|
fi
|
|
}
|
|
|
|
leave_alt_screen() {
|
|
if [ "${ALT_SCREEN_ACTIVE}" = "1" ] && command_exists tput; then
|
|
tput cnorm || true
|
|
tput rmcup || true
|
|
ALT_SCREEN_ACTIVE=0
|
|
fi
|
|
}
|