fish: conf.d: Drop setting of some environment variables

These have now been moved to environment.d and get set by systemd.

https://wiki.archlinux.org/title/Systemd/User#Environment_variables
This commit is contained in:
Sanchayan Maity 2022-10-02 10:59:32 +05:30
parent 0fcf2563ad
commit 68da927ad3

View file

@ -1,40 +1,10 @@
function __fish_setup_on_tty_login --description "Set up environment on tty login" function __fish_setup_on_tty_login --description "Set up environment on tty login"
set -qx XDG_CONFIG_HOME; or set -Ux XDG_CONFIG_HOME $HOME/.config
set -qx XDG_CACHE_HOME; or set -Ux XDG_CACHE_HOME $HOME/.cache
set -qx XDG_DATA_HOME; or set -Ux XDG_DATA_HOME $HOME/.local/share
set -qx XDG_STATE_HOME; or set -Ux XDG_STATE_HOME $HOME/.local/state
set -qx SSH_AUTH_SOCK; or set -Ux SSH_AUTH_SOCK $XDG_RUNTIME_DIR/ssh-agent.socket
# Wayland session
set -qx XDG_SESSION_TYPE; or set -Ux XDG_SESSION_TYPE wayland
set -qx XDG_SESSION_DESKTOP; or set -Ux XDG_SESSION_DESKTOP wayland
set -qx XDG_CURRENT_DESKTOP; or set -Ux XDG_CURRENT_DESKTOP wayland
# Firefox
set -qx MOZ_ENABLE_WAYLAND; or set -Ux MOZ_ENABLE_WAYLAND 1
set -qx MOZ_DBUS_REMOTE; or set -Ux MOZ_DBUS_REMOTE 1
# QT
set -qx QT_QPA_PLATFORM; or set -Ux QT_QPA_PLATFORM wayland
set -qx QT_QPA_PLATFORMTHEME; or set -Ux QT_QPA_PLATFORMTHEME qt5ct
for extra_path in ~/.{local,nix-profile,cargo,cabal,ghcup}/bin for extra_path in ~/.{local,nix-profile,cargo,cabal,ghcup}/bin
if test -d "$extra_path" if test -d "$extra_path"
set -gxp PATH "$extra_path" set -gxp PATH "$extra_path"
end end
end end
if type -qf nvim
set -gx EDITOR nvim
set -gx VISUAL nvim
set -gx MANPAGER 'nvim +Man!'
else
if type -qf vim
set -gx EDITOR vim
set -gx VISUAL vim
end
end
if test -d {$HOME}/.nix-defexpr/channels if test -d {$HOME}/.nix-defexpr/channels
set -gx NIX_PATH {$HOME}/.nix-defexpr/channels set -gx NIX_PATH {$HOME}/.nix-defexpr/channels
set -gx NIX_SSL_CERT_FILE '/etc/ssl/certs/ca-certificates.crt' set -gx NIX_SSL_CERT_FILE '/etc/ssl/certs/ca-certificates.crt'
@ -57,16 +27,16 @@ function __fish_setup_on_tty_login --description "Set up environment on tty logi
fnm env --shell=fish --log-level=quiet | source fnm env --shell=fish --log-level=quiet | source
end end
set -gx CLICOLOR 1 # Temporary directory for GStreamer dot files
set -gx LSCOLORS gxfxcxdxbxegedabaggxgx
set -Ux GST_DEBUG_NO_COLOR 1
set -Ux GST_DEBUG_COLOR_MODE off
mkdir -p /tmp/gst-dot mkdir -p /tmp/gst-dot
set -Ux GST_DEBUG_DUMP_DOT_DIR /tmp/gst-dot
set -Ux GHCUP_USE_XDG_DIRS 1 # Needed for silencing some warnings from Sway. Will not work with systemd
# environment.d.
set -gx WLR_NO_HARDWARE_CURSORS 1
# Required for all environment variables to be set correctly, especially
# in tmux session service.
dbus-update-activation-environment --systemd --all
end end
# Instead of tty check, we would have liked to do this using status is-login # Instead of tty check, we would have liked to do this using status is-login