From 3e8153e140ef55868310656ca4ea1b91aee7d561 Mon Sep 17 00:00:00 2001 From: Maas Lalani Date: Mon, 11 Jul 2022 17:18:06 -0400 Subject: [PATCH] fix(write): Add CtrlD as a quitting key Add tea.KeyCtrlD as a way to quit the write as it signifies EOF. --- write/write.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/write/write.go b/write/write.go index 5d84a6f..41e539f 100644 --- a/write/write.go +++ b/write/write.go @@ -21,7 +21,7 @@ func (m model) Update(msg tea.Msg) (tea.Model, tea.Cmd) { switch msg := msg.(type) { case tea.KeyMsg: switch msg.Type { - case tea.KeyEscape, tea.KeyCtrlC: + case tea.KeyEscape, tea.KeyCtrlC, tea.KeyCtrlD: m.quitting = true return m, tea.Quit }