Fix --stdin-add-formatting not working

Fixes #2512
This commit is contained in:
Kovid Goyal 2020-04-06 09:35:16 +05:30
parent 40341d2ddd
commit 590a4d70ee
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C
2 changed files with 5 additions and 0 deletions

View File

@ -12,6 +12,8 @@ To update |kitty|, :doc:`follow the instructions <binary>`.
- X11: Fix crash when doing drag and drop from some applications (:iss:`2505`)
- Fix :option:`launch --stdin-add-formatting` not working (:iss:`2512`)
0.17.2 [2020-03-29]
--------------------

View File

@ -277,6 +277,9 @@ def launch(boss: Boss, opts: LaunchCLIOptions, args: List[str], target_tab: Opti
kw['overlay_for'] = active.id
if opts.stdin_source and opts.stdin_source != 'none':
q = opts.stdin_source
if opts.stdin_add_formatting:
if q in ('@screen', '@screen_scrollback', '@alternate', '@alternate_scrollback'):
q = '@ansi_' + q[1:]
if opts.stdin_add_line_wrap_markers:
q += '_wrap'
penv, stdin = boss.process_stdin_source(window=active, stdin=q)