From 96f552128609dfe017e36c750fcfcc7e3dda6a19 Mon Sep 17 00:00:00 2001 From: Glenn Date: Mon, 20 Nov 2023 12:28:06 +0100 Subject: [PATCH] fix: add workaround preserving terminal integrity --- src/test.cr | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/test.cr b/src/test.cr index b1356f7..6b9e3f0 100644 --- a/src/test.cr +++ b/src/test.cr @@ -47,13 +47,13 @@ tput.listen do |char, key, sequence| # were consumed as part of identifying the key that was # pressed. if char == 'q' - tput.normal_buffer + # tput.normal_buffer # tput.reset_cursor # tput.exit_alt_charset_mode # tput.attr("normal", 1) # tput.soft_reset - system("stty echo") - exit + # system("stty echo") + break else tput.cr tput.lf @@ -61,3 +61,5 @@ tput.listen do |char, key, sequence| end end +tput.normal_buffer +# tput.clear