From 8cd2188e7f565e124e04dc59433715012f94c371 Mon Sep 17 00:00:00 2001 From: Keiichi Shimamura Date: Thu, 9 Mar 2023 18:10:27 -0500 Subject: [PATCH] remove usage of wslvar/wslu --- import.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/import.sh b/import.sh index 238992c..d047286 100755 --- a/import.sh +++ b/import.sh @@ -3,7 +3,8 @@ # run from repo root # ./import.sh -USERPROFILE=$(wslvar USERPROFILE) +CMDSHELL="$(command -v cmd.exe || echo '/mnt/c/Windows/system32/cmd.exe')" +USERPROFILE="$($CMDSHELL /d /v:off /c 'echo | set /p t=%USERPROFILE%' 2>/dev/null)" DUMP=wsl-vpnkit.tar.gz # build if necessary