From 6da36f4ae5d961c9c198ced803cd2297368e3f24 Mon Sep 17 00:00:00 2001 From: Nethum Lamahewage Date: Thu, 4 Jan 2024 20:03:00 +0530 Subject: [PATCH] history: fix deleting last entry (cherry picked from commit a36ff7d143ffe54ff40ed47ad15099522021edac) --- share/functions/history.fish | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/functions/history.fish b/share/functions/history.fish index 09b078fff..2bb9fdd4a 100644 --- a/share/functions/history.fish +++ b/share/functions/history.fish @@ -174,7 +174,7 @@ function history --description "display or manipulate interactive command histor end if string match -qr '^[1-9][0-9]*$' -- $i - and test $i -lt $found_items_count + and test $i -le $found_items_count set -a choices $i else printf (_ "Ignoring invalid history entry ID \"%s\"\n") $i