From 1559a2e15a12e06dd4810045e401d8ae52e13083 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Mon, 5 Sep 2022 21:19:58 +0530 Subject: [PATCH] Cleanup previous PR --- kitty_tests/shell_integration.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kitty_tests/shell_integration.py b/kitty_tests/shell_integration.py index 588d8de0a..82bd64bcc 100644 --- a/kitty_tests/shell_integration.py +++ b/kitty_tests/shell_integration.py @@ -25,10 +25,10 @@ def bash_ok(): v = shutil.which('bash') if not v: return False - o = subprocess.check_output([v, '-c', 'echo "${BASH_VERSINFO[0]}\n${BASH_VERSINFO[4]}"']).decode('utf-8').strip() + o = subprocess.check_output([v, '-c', 'echo "${BASH_VERSINFO[0]}\n${BASH_VERSINFO[4]}"']).decode('utf-8').splitlines() if not o: return False - (major_ver, relstatus) = o.split(maxsplit=2) + major_ver, relstatus = o[0], o[-1] return int(major_ver) >= 5 and relstatus == 'release'