xontrib-sh
xontrib-sh copied to clipboard
Support updating environment variables
The idea:
- Get
prev_env = $(env)before running the sh-command - Run sh-command. Example
! export QWE=123. - Add saving env at the end of command:
! export QWE=123 ; env > /tmp/post_env. - By comparing
prev_envandpost_envupdate the environment in the current session i.e.$QWE='123'
For community
⬇️ Please click the 👍 reaction instead of leaving a +1 or 👍 comment