Fix ZSH configuration for WSL
This commit is contained in:
@@ -1,3 +0,0 @@
|
||||
#/usr/bin/env bash
|
||||
|
||||
export DOTFILES="$HOME/.dotfiles"
|
||||
@@ -1,3 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
export EDITOR=vim
|
||||
@@ -1,38 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
is_debian_based() {
|
||||
# Checking /etc/os-release
|
||||
if [[ -f /etc/os-release ]]; then
|
||||
. /etc/os-release
|
||||
if [[ "$ID_LIKE" == *"debian"* ]] || [[ "$ID" == "debian" ]]; then
|
||||
return 0 # OK: Debian-based
|
||||
fi
|
||||
fi
|
||||
|
||||
# Alternative check: /etc/debian_version
|
||||
if [[ -f /etc/debian_version ]]; then
|
||||
return 0 # OK: Debian-based
|
||||
fi
|
||||
|
||||
return 1 # NO Debian-based
|
||||
}
|
||||
|
||||
# Add fzf keybindings and enhancements
|
||||
if is_debian_based; then
|
||||
export FZF_CTRL_T_COMMAND="fdfind --type f"
|
||||
export FZF_ALT_C_COMMAND="fdfind --type d"
|
||||
else
|
||||
export FZF_CTRL_T_COMMAND="fd --type f"
|
||||
export FZF_ALT_C_COMMAND="fd --type d"
|
||||
fi
|
||||
|
||||
export FZF_CTRL_R_OPTS="--preview 'echo {}'"
|
||||
|
||||
# Export Catppuccin Mocha theme for FZF
|
||||
export FZF_DEFAULT_OPTS=" \
|
||||
--height 60% --layout=reverse --border \
|
||||
--color=bg+:#313244,bg:#1E1E2E,spinner:#F5E0DC,hl:#F38BA8 \
|
||||
--color=fg:#CDD6F4,header:#F38BA8,info:#CBA6F7,pointer:#F5E0DC \
|
||||
--color=marker:#B4BEFE,fg+:#CDD6F4,prompt:#CBA6F7,hl+:#F38BA8 \
|
||||
--color=selected-bg:#45475A \
|
||||
--color=border:#313244,label:#CDD6F4"
|
||||
@@ -1,3 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
[ -f "$HOME/.ghcup/env" ] && . "$HOME/.ghcup/env"
|
||||
@@ -1,12 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
case $(uname -s) in
|
||||
"Linux")
|
||||
export GOPATH="$HOME/.local/share/Go";;
|
||||
"Darwin")
|
||||
export GOPATH="$HOME/Library/Go";;
|
||||
*)
|
||||
echo "Operating System unknown";;
|
||||
esac
|
||||
|
||||
export GOBIN=$GOPATH/bin
|
||||
@@ -1,3 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
export GRAALVM_HOME="${HOME}/.local/share/mise/installs/java/graalvm-community-23.0.1"
|
||||
@@ -1,5 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
if [[ $SHELL == "zsh" ]]; then
|
||||
export HELPDIR=/usr/share/zsh/"${ZSH_VERSION}"/help
|
||||
fi
|
||||
@@ -1,3 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
export HOMEBREW_NO_ENV_HINTS=1
|
||||
@@ -1,3 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
export JAVA_HOME="${HOME}/.local/share/mise/installs/java/23.0.1"
|
||||
@@ -1,4 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
JMETER_HOME="$(which jmeter)"
|
||||
export JMETER_HOME
|
||||
@@ -1,5 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
if [ -e "$HOME/.cargo" ]; then
|
||||
source "$HOME/.cargo/env"
|
||||
fi
|
||||
@@ -1,55 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
if [ -z "$DISPLAY" ] && [ "$(tty)" = "/dev/tty1" ]; then
|
||||
if [ -n "$DBUS_SESSION_BUS_ADDRESS" ]; then
|
||||
|
||||
# XDG Settings Basic
|
||||
export XDG_CONFIG_HOME=${HOME}/.config
|
||||
export XDG_DATA_HOME=${HOME}/.local/share
|
||||
export XDG_CACHE_HOME=${HOME}/.local/cache
|
||||
export XDG_STATE_HOME=${HOME}/.local/state
|
||||
|
||||
# XDG_CONFIG_HOME
|
||||
export GTK2_RC_FILES=${XDG_CONFIG_HOME}/gtk-2.0/gtkrc-2.0
|
||||
|
||||
# Reduces crashs for some gdk apps, like evolution
|
||||
# ! Do not set as global variable. Electron Apps will not start !
|
||||
# export GDK_BACKEND=wayland
|
||||
|
||||
# Required for tray icons on waybar
|
||||
export XDG_CURRENT_DESKTOP=sway
|
||||
|
||||
# Enable QT apps to have gtk theme
|
||||
export QT_QPA_PLATFORMTHEME=qt5ct
|
||||
|
||||
# Force wayland on qt apps
|
||||
export QT_QPA_PLATFORM=wayland
|
||||
|
||||
export QT_WAYLAND_DISABLE_WINDOWDECORATION=1
|
||||
# Explicitly set to '96' instead of 'physical' because some apps have problems
|
||||
# Looking at you nextcloud client!
|
||||
# https://github.com/nextcloud/desktop/issues/1079
|
||||
# https://github.com/swaywm/sway/issues/2424
|
||||
export QT_WAYLAND_FORCE_DPI=96
|
||||
|
||||
# Make Qt apps honour DPI settings.
|
||||
export QT_AUTO_SCREEN_SCALE_FACTOR=1
|
||||
|
||||
# Mozilla Wayland support + hardware video decoding
|
||||
export MOZ_ENABLE_WAYLAND=1
|
||||
export MOZ_WAYLAND_USE_VAAPI=1
|
||||
|
||||
# SDL
|
||||
export SDL_VIDEODRIVER=wayland
|
||||
|
||||
# Java under Xwayland
|
||||
export _JAVA_AWT_WM_NONREPARENTING=1
|
||||
|
||||
# Session Type for later screensharing
|
||||
export XDG_SESSION_TYPE=wayland
|
||||
|
||||
exec dbus-launch --exit-with-session sway
|
||||
else
|
||||
echo "Cannot found dbus session: Sway don't work"
|
||||
fi
|
||||
fi
|
||||
@@ -1,3 +0,0 @@
|
||||
#/usr/bin/env bash
|
||||
|
||||
export VIRTUAL_ENV_DISABLE_PROMPT=1
|
||||
Reference in New Issue
Block a user