diff --git a/docs/changelog.rst b/docs/changelog.rst index f4a1ccd96..6868d231f 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -129,6 +129,9 @@ To update |kitty|, :doc:`follow the instructions `. It can now increment font size and reset it. It also only acts on the active top-level window, by default (:iss:`1581`) +- When launching child processes set the :code:`PWD` environment variable + (:iss:`1595`) + 0.13.3 [2019-01-19] ------------------------------ diff --git a/kitty/child.py b/kitty/child.py index fc91bd1bc..50a4ac460 100644 --- a/kitty/child.py +++ b/kitty/child.py @@ -168,6 +168,8 @@ class Child: env.update(self.env) env['TERM'] = self.opts.term env['COLORTERM'] = 'truecolor' + if self.cwd: + env['PWD'] = self.cwd if os.path.isdir(terminfo_dir): env['TERMINFO'] = terminfo_dir env = tuple('{}={}'.format(k, v) for k, v in env.items())