Skip to content

Instantly share code, notes, and snippets.

View rodrigojusto's full-sized avatar

Rodrigo Souza Justo rodrigojusto

View GitHub Profile
@ThYpHo0n
ThYpHo0n / .zshrc
Last active August 5, 2024 01:37
WSL(2) bash profile helpers
# WSL?
if [[ "$(< /proc/sys/kernel/osrelease)" == *microsoft* ]]; then
export $(dbus-launch)
export LIBGL_ALWAYS_INDIRECT=1
export WSL_VERSION=$(wsl.exe -l -v | grep -a '[*]' | sed 's/[^0-9]*//g')
export WSL_HOST=$(tail -1 /etc/resolv.conf | cut -d' ' -f2)
export DISPLAY=$WSL_HOST:0
# pip path if using --user
export PATH=$PATH:$HOME/.local/bin
# SSH