[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: reset key bindings

From: Andrey Butirsky
Subject: Re: reset key bindings
Date: Tue, 31 Dec 2019 05:29:31 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:72.0) Gecko/20100101 Thunderbird/72.0

On 31.12.2019 05:17, Marco Ippolito wrote:
On 30/12/2019 16:10, Andrey Butirsky wrote:
Didn't think about "exec bash", thanks. However, it's essentially a restarting. So you loose the environment, e.g.

If by "environment" you mean the exported environment variables.. `exec' "retains" them, they will be accessible:

export EXPORTED=foo; non_exported=bar; exec bash -c 'echo "$EXPORTED $non_exported"'

-> foo

(perhaps run the above after having run an additional copy of bash if your terminal program, say gnome-terminal, closes the window when the shell exits, as the exec'd bash will exit immediately after echo'ing).

Or, what you mean by "environment"?

Sorry, I was unclear. Of course the environment will be preserved. I meant, the nonexported shell variables will not.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]