From ea45dfea50b8eac85da86acb570e536f86b39da3 Mon Sep 17 00:00:00 2001 From: DarkWiiPlayer Date: Wed, 28 Feb 2024 23:21:03 +0100 Subject: [PATCH] Add shell alias to set wezterm variables --- shell/alias | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/shell/alias b/shell/alias index dafec8e..4d09ffa 100644 --- a/shell/alias +++ b/shell/alias @@ -20,6 +20,15 @@ alias setclip='xclip -selection c' alias tmux='tmux -2' alias w='watch -t -d -n 1' alias wmu='wake-me-up' +if [ "$TERM_PROGRAM" = "WezTerm" ] + +then wezvar() { + name="$1"; shift + value="$*" + printf "\033]1337;SetUserVar=%s=%s\007" "$name" $(echo -n "$value" | base64) +} +fi + pp() { cd $(find-git-project $HOME/workspace "$@") }