KSI should be set even when no-rc is specified

This commit is contained in:
Kovid Goyal
2021-11-07 10:10:19 +05:30
parent 35514e0cc3
commit 4c0a7a9566

View File

@@ -118,14 +118,16 @@ def setup_shell_integration(opts: Options, env: Dict[str, str]) -> bool:
return True
def modify_shell_environ(argv0: str, opts: Options, env: Dict[str, str]) -> bool:
def modify_shell_environ(argv0: str, opts: Options, env: Dict[str, str]) -> None:
if 'disabled' in set(opts.shell_integration.split()):
return
env['KITTY_SHELL_INTEGRATION'] = opts.shell_integration
if not shell_integration_allows_rc_modification(opts):
return False
return
shell = get_supported_shell_name(argv0)
if shell is None:
return False
return
f = ENV_MODIFIERS.get(shell)
if f is not None:
f(env)
env['KITTY_SHELL_INTEGRATION'] = opts.shell_integration
return True
return