Browse Source

added print to the quit function to clear the terminal

aeth 1 tháng trước cách đây
mục cha
commit
7b9144d98a
1 tập tin đã thay đổi với 1 bổ sung0 xóa
  1. 1 0
      pkg/userinterface.go

+ 1 - 0
pkg/userinterface.go

@@ -231,6 +231,7 @@ func (m model) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
 
 		// These keys should exit the program.
 		case "ctrl+c", "q":
+			fmt.Print("\033[H\033[2J")
 			return m, tea.Quit
 
 		// The "up" and "k" keys move the cursor up