mirror of
https://git.disroot.org/FollieHiyuki/dotfiles.git
synced 2024-12-02 04:08:30 -05:00
forgit: fix setting env logic
This commit is contained in:
parent
93800d7ac4
commit
0d71225bcd
@ -674,15 +674,17 @@ if [ ! -f "$BASH_COMPLETION_USER_DIR/plugins/forgit.plugin.bash" ]; then
|
|||||||
fi
|
fi
|
||||||
source $BASH_COMPLETION_USER_DIR/plugins/forgit.plugin.sh
|
source $BASH_COMPLETION_USER_DIR/plugins/forgit.plugin.sh
|
||||||
|
|
||||||
|
if [ -n "$XDG_SESSION_TYPE" ]; then
|
||||||
if [ "$XDG_SESSION_TYPE" = "wayland" ]; then
|
if [ "$XDG_SESSION_TYPE" = "wayland" ]; then
|
||||||
export FORGIT_COPY_CMD="wl-copy"
|
export FORGIT_COPY_CMD="wl-copy"
|
||||||
elif [ "$XDG_SESSION_TYPE" = "x11" ]; then
|
else
|
||||||
if command -v xclip >/dev/null; then
|
if command -v xclip >/dev/null; then
|
||||||
export FORGIT_COPY_CMD="xclip -selection clipboard"
|
export FORGIT_COPY_CMD="xclip -selection clipboard"
|
||||||
else
|
else
|
||||||
export FORGIT_COPY_CMD="xsel -i -b"
|
export FORGIT_COPY_CMD="xsel -i -b"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
# If I don't want starship
|
# If I don't want starship
|
||||||
# source $BASH_COMPLETION_USER_DIR/plugins/prompt.bash
|
# source $BASH_COMPLETION_USER_DIR/plugins/prompt.bash
|
||||||
|
@ -101,15 +101,17 @@ set -gx _ZO_RESOLVE_SYMLINKS 1
|
|||||||
# set -gx _ZL_ROOT_MARKERS ".git,.svn,.hg,.root,package.json,.projectile,.pro"
|
# set -gx _ZL_ROOT_MARKERS ".git,.svn,.hg,.root,package.json,.projectile,.pro"
|
||||||
# set -gx RANGER_ZLUA $HOME/.config/fish/z.lua
|
# set -gx RANGER_ZLUA $HOME/.config/fish/z.lua
|
||||||
# forgit
|
# forgit
|
||||||
|
if test -n "$XDG_SESSION_TYPE"
|
||||||
if test $XDG_SESSION_TYPE = "wayland"
|
if test $XDG_SESSION_TYPE = "wayland"
|
||||||
set -gx FORGIT_COPY_CMD wl-copy
|
set -gx FORGIT_COPY_CMD wl-copy
|
||||||
else if test $XDG_SESSION_TYPE = "x11"
|
else
|
||||||
if command -v xclip >/dev/null
|
if command -v xclip >/dev/null
|
||||||
set -gx FORGIT_COPY_CMD "xclip -selection clipboard"
|
set -gx FORGIT_COPY_CMD "xclip -selection clipboard"
|
||||||
else
|
else
|
||||||
set -gx FORGIT_COPY_CMD "xsel -i -b"
|
set -gx FORGIT_COPY_CMD "xsel -i -b"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
end
|
||||||
# nnn
|
# nnn
|
||||||
if command -v nnn >/dev/null
|
if command -v nnn >/dev/null
|
||||||
set -gx TERMINAL alacritty
|
set -gx TERMINAL alacritty
|
||||||
|
@ -387,15 +387,17 @@ export ABBR_USER_ABBREVIATIONS_FILE="$HOME/.local/share/zsh/abbreviations"
|
|||||||
# gencomp
|
# gencomp
|
||||||
export GENCOMP_DIR=$XDG_DATA_HOME/zsh/completions
|
export GENCOMP_DIR=$XDG_DATA_HOME/zsh/completions
|
||||||
# forgit
|
# forgit
|
||||||
|
if [ -n "$XDG_SESSION_TYPE" ]; then
|
||||||
if [ "$XDG_SESSION_TYPE" = "wayland" ]; then
|
if [ "$XDG_SESSION_TYPE" = "wayland" ]; then
|
||||||
export FORGIT_COPY_CMD="wl-copy"
|
export FORGIT_COPY_CMD="wl-copy"
|
||||||
elif [ "$XDG_SESSION_TYPE" = "x11" ]; then
|
else
|
||||||
if command -v xclip >/dev/null; then
|
if command -v xclip >/dev/null; then
|
||||||
export FORGIT_COPY_CMD="xclip -selection clipboard"
|
export FORGIT_COPY_CMD="xclip -selection clipboard"
|
||||||
else
|
else
|
||||||
export FORGIT_COPY_CMD="xsel -i -b"
|
export FORGIT_COPY_CMD="xsel -i -b"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
# PATH
|
# PATH
|
||||||
typeset -U PATH path
|
typeset -U PATH path
|
||||||
|
Loading…
Reference in New Issue
Block a user