From 47aae7f1f70a41142da28ef797b5ed5457f20ca9 Mon Sep 17 00:00:00 2001 From: Richard Blair Date: Tue, 31 Aug 2021 18:10:24 -0400 Subject: [PATCH] Added fool-proof way of passing Windows PATH over to WSL after genie is initialized. --- ellipsis.sh | 2 ++ zshrc | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/ellipsis.sh b/ellipsis.sh index 3e34673..bc809a3 100755 --- a/ellipsis.sh +++ b/ellipsis.sh @@ -63,6 +63,8 @@ pkg.init() { # Check if systemd-genie is installed, and let's execute that if we're not in a bottle. if [ "$INSIDE_GENIE" != true ]; then if [ -e /etc/genie.ini ]; then + # I don't trust genie to preserve the Windows path, so we're going to do it + echo "export PATH=\$PATH:\"$PATH\"" >$HOME/.shell/etc/env genie -s exit 0 fi diff --git a/zshrc b/zshrc index 8a68220..9c44dd9 100644 --- a/zshrc +++ b/zshrc @@ -1,5 +1,7 @@ if [ "$INSIDE_GENIE" = true ]; then - # Do nothing + if [ -e "$HOME/.shell/etc/env" ]; then + source $HOME/.shell/etc/env + fi fi declare -x PATH=$PATH:$HOME/.ellipsis/bin