mirror of
https://git.disroot.org/FollieHiyuki/dotfiles.git
synced 2024-11-25 00:38:23 -05:00
forgit: fix setting env logic
This commit is contained in:
parent
0423ec56e6
commit
622b6e4e63
@ -674,13 +674,15 @@ 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 [ "$XDG_SESSION_TYPE" = "wayland" ]; then
|
if [ -n "$XDG_SESSION_TYPE" ]; then
|
||||||
export FORGIT_COPY_CMD="wl-copy"
|
if [ "$XDG_SESSION_TYPE" = "wayland" ]; then
|
||||||
elif [ "$XDG_SESSION_TYPE" = "x11" ]; then
|
export FORGIT_COPY_CMD="wl-copy"
|
||||||
if command -v xclip >/dev/null; then
|
|
||||||
export FORGIT_COPY_CMD="xclip -selection clipboard"
|
|
||||||
else
|
else
|
||||||
export FORGIT_COPY_CMD="xsel -i -b"
|
if command -v xclip >/dev/null; then
|
||||||
|
export FORGIT_COPY_CMD="xclip -selection clipboard"
|
||||||
|
else
|
||||||
|
export FORGIT_COPY_CMD="xsel -i -b"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -101,13 +101,15 @@ 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 $XDG_SESSION_TYPE = "wayland"
|
if test -n "$XDG_SESSION_TYPE"
|
||||||
set -gx FORGIT_COPY_CMD wl-copy
|
if test $XDG_SESSION_TYPE = "wayland"
|
||||||
else if test $XDG_SESSION_TYPE = "x11"
|
set -gx FORGIT_COPY_CMD wl-copy
|
||||||
if command -v xclip >/dev/null
|
|
||||||
set -gx FORGIT_COPY_CMD "xclip -selection clipboard"
|
|
||||||
else
|
else
|
||||||
set -gx FORGIT_COPY_CMD "xsel -i -b"
|
if command -v xclip >/dev/null
|
||||||
|
set -gx FORGIT_COPY_CMD "xclip -selection clipboard"
|
||||||
|
else
|
||||||
|
set -gx FORGIT_COPY_CMD "xsel -i -b"
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
# nnn
|
# nnn
|
||||||
|
@ -387,13 +387,15 @@ 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 [ "$XDG_SESSION_TYPE" = "wayland" ]; then
|
if [ -n "$XDG_SESSION_TYPE" ]; then
|
||||||
export FORGIT_COPY_CMD="wl-copy"
|
if [ "$XDG_SESSION_TYPE" = "wayland" ]; then
|
||||||
elif [ "$XDG_SESSION_TYPE" = "x11" ]; then
|
export FORGIT_COPY_CMD="wl-copy"
|
||||||
if command -v xclip >/dev/null; then
|
|
||||||
export FORGIT_COPY_CMD="xclip -selection clipboard"
|
|
||||||
else
|
else
|
||||||
export FORGIT_COPY_CMD="xsel -i -b"
|
if command -v xclip >/dev/null; then
|
||||||
|
export FORGIT_COPY_CMD="xclip -selection clipboard"
|
||||||
|
else
|
||||||
|
export FORGIT_COPY_CMD="xsel -i -b"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user