diff options
author | Alan Pearce | 2022-06-13 03:01:02 +0200 |
---|---|---|
committer | Alan Pearce | 2022-06-13 03:01:02 +0200 |
commit | 0220e076b784d80125687e5361eb11073e43059d (patch) | |
tree | 6e63a6a0d6c7f7d59985102d401599f57c9475b5 /user/zsh | |
parent | 28703f6e2748c335c90ef0c1dbe6fc6eaae7de8f (diff) | |
download | nixfiles-0220e076b784d80125687e5361eb11073e43059d.tar.lz nixfiles-0220e076b784d80125687e5361eb11073e43059d.tar.zst nixfiles-0220e076b784d80125687e5361eb11073e43059d.zip |
zsh: add helpers to copy/set environment variables in Emacs
Diffstat (limited to 'user/zsh')
-rw-r--r-- | user/zsh/zshrc | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/user/zsh/zshrc b/user/zsh/zshrc index f9f9c984..c63dace2 100644 --- a/user/zsh/zshrc +++ b/user/zsh/zshrc @@ -149,3 +149,11 @@ add_project () { project=${1:-$PWD} emacsclient -e "(projectile-add-known-project \"${project}\")" } + +esetenv () { + emacsclient -e "(setenv \"$1\" \"$2\")" +} + +ecpenv () { + esetenv "$1" "${(P)1}" +} |