From e27bf17180068609a66d329d75e8a0f979b4bda8 Mon Sep 17 00:00:00 2001 From: Christoffer Martinsson Date: Fri, 4 Oct 2024 18:24:47 +0200 Subject: [PATCH] Testing --- update.sh | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/update.sh b/update.sh index 9e1a7cb..6e520d3 100755 --- a/update.sh +++ b/update.sh @@ -22,6 +22,12 @@ else DESKTOP="no" fi +if [ "$(systemd-detect-virt)" == "wsl" ]; then + WSL="yes" +else + WSL="no" +fi + # Ubuntu 20.04 workaround printf -- '\033[33m Remove neovim if already installed\n\033[37m' if [ "$(dpkg -l | awk '/nala/ {print }'|wc -l)" -ge 1 ]; then @@ -351,7 +357,7 @@ echo 'alias lss="eza -1 -l --icons=auto -h -g --total-size -o --no-permissions - echo 'source ~/.fzf.bash' >> ~/.bashrc echo 'eval "$(zoxide init bash)"' >> ~/.bashrc -if [ $DESKTOP == "no" ]; then +if [ $DESKTOP == "no" ] && [ $WSL == "no" ]; then # Add tmux/nvim autostart to bashrc printf -- '\033[33m Adding tmux/nvim autostart to bashrc\n\033[37m' echo "# TMUX" >> ~/.bashrc @@ -362,7 +368,7 @@ if [ $DESKTOP == "no" ]; then echo "fi" >> ~/.bashrc fi -if [ $DESKTOP == "yes" ]; then +if [ $DESKTOP == "yes" ] || [ $WSL == "yes" ]; then # Add tmux/nvim autostart to bashrc printf -- '\033[33m Adding tmux/nvim autostart to bashrc\n\033[37m' echo "# TMUX" >> ~/.bashrc