alternative buffer thing moment
This commit is contained in:
parent
41b1a0b70a
commit
d063287a30
2
main.sh
2
main.sh
|
@ -52,6 +52,7 @@ do radios+=("`$JQ ".icestats.source[${song}].server_name" <<< "${jsonData}" | s
|
|||
urls+=("`$JQ ".icestats.source[${song}].listenurl" <<< "${jsonData}" | sed 's|^\"||g;s|\"$||g'`")
|
||||
done
|
||||
|
||||
printf '\033[?1049h\033[0H' # start alternative buffer thing
|
||||
while :
|
||||
do clear
|
||||
jsonData="$(curl -s "$url"/status-json.xsl)"
|
||||
|
@ -83,6 +84,7 @@ do clear
|
|||
select=$(timeout --foreground ${tout} fzf --reverse --height=~25 <<< "$(printf "$list\nq exit")"| awk '{print $1}')
|
||||
[ "${select}" == "q" ] && {
|
||||
kill $mpvpid 2>/dev/null
|
||||
printf '\033[?1049l' # stop alternative buffer thing
|
||||
exit
|
||||
}
|
||||
done
|
||||
|
|
Loading…
Reference in New Issue