Skip to content

Instantly share code, notes, and snippets.

@BrandonLWhite
Created May 8, 2020 19:34
Show Gist options
  • Save BrandonLWhite/beb66d0cc3e60d1856ae91fb3027cc4a to your computer and use it in GitHub Desktop.
Save BrandonLWhite/beb66d0cc3e60d1856ae91fb3027cc4a to your computer and use it in GitHub Desktop.
Bash script to launch GitExtensions (Windowsland) from WSL2 bash path.
#!/bin/bash
LINUX_PATH=$(pwd)
#echo ${LINUX_PATH}
WINDOWS_PATH="\"U:${LINUX_PATH//\//\\}\""
#echo ${WINDOWS_PATH}
GIT_EXTENSIONS_PATH="\"/mnt/c/Program Files (x86)/GitExtensions/GitExtensions.exe\""
GIT_EXTENSIONS_COMMAND="${GIT_EXTENSIONS_PATH} browse ${WINDOWS_PATH}"
echo ${GIT_EXTENSIONS_COMMAND}
eval ${GIT_EXTENSIONS_COMMAND} &
@BrandonLWhite
Copy link
Author

Here I have my Ubuntu distro root mounted as "U:" drive in Windows. GitExtensions does not work with \wsl$\ paths.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment