From cb09ae3e84f4b0e237f9451decc7dfffdb88d4f5 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Sun, 28 Nov 2021 10:23:32 +0530 Subject: [PATCH] ... --- kitty/complete.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kitty/complete.py b/kitty/complete.py index 8b007fc14..32232098c 100644 --- a/kitty/complete.py +++ b/kitty/complete.py @@ -648,7 +648,7 @@ def find_completions(words: Sequence[str], new_word: bool, entry_points: Iterabl return ans words = words[1:] if not words or (len(words) == 1 and not new_word): - if words[0].startswith('--') and '=' in words[0]: + if words and words[0].startswith('--') and '=' in words[0]: complete_cli(ans, words, new_word, options_for_completion(), complete_kitty_cli_arg) return ans prefix = words[0] if words else ''