Closed marlof closed 5 years ago
Try a read -t -n 265 discard or while read -r -t 0 ; do read -r; done
Test with
Run scorch
Press 1 (not not press enter)
wait for a screen refresh
Press
read -t 0 -n 256 discard FAILED
Clear buffer doesnt seem to work in several ways of testing.
Is your feature request related to a problem? Please describe. Sometimes between screen refreshes, the keyboard buffer maybe active but not shown
Describe the solution you'd like Clear the keyboard buffer
Example of how to do it it to discard input within 1 second of refresh read -e t1