From 32f22e0ada2fd24338a2377e1cfbeb33bb780944 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Fri, 22 Jun 2018 17:23:01 +0530 Subject: [PATCH] kitty shell: Ignore failure to read readline history file --- kitty/shell.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/kitty/shell.py b/kitty/shell.py index b4b8f26d3..35756077d 100644 --- a/kitty/shell.py +++ b/kitty/shell.py @@ -84,8 +84,10 @@ class Completer: return self.matches[state] def __enter__(self): - if os.path.exists(self.history_path): + try: readline.read_history_file(self.history_path) + except Exception: + pass readline.set_completer(self.complete) delims = readline.get_completer_delims() readline.set_completer_delims(delims.replace('-', ''))