zshrc: add hostname checks

This commit is contained in:
leo 2023-07-01 23:56:45 +02:00
parent 56a026f30e
commit 34d05a85e5
Signed by: wanderer
SSH Key Fingerprint: SHA256:Dp8+iwKHSlrMEHzE3bJnPng70I7LEsa3IJXRH/U+idQ

8
.zshrc

@ -127,7 +127,8 @@
export FZF_CTRL_T_OPTS="--preview 'exa -al --group --group-directories-first --colour-scale --list-dirs --icons --git --time-style=full-iso {}' --bind '?:preview:bat --style=numbers --color=always --line-range :200 {}'"
export FZF_ALT_C_OPTS="--preview 'exa -al --group --group-directories-first --colour-scale --icons --git --time-style=full-iso {}' --bind '?:preview:exa -al --group --group-directories-first --colour-scale --list-dirs --icons --git --time-style=full-iso {}'"
if [[ "$(hostnamectl hostname)" == "leo" ]]; then
# if [[ "$(hostnamectl hostname)" == "leo" ]]; then
if [[ "$(hostname -s)" == "leo" ]]; then
local fzf_bindings="/usr/share/fzf/key-bindings.zsh"
else
local fzf_bindings="/usr/share/fzf/shell/key-bindings.zsh"
@ -163,11 +164,14 @@
export QT_IM_MODULE=ibus
export XMODIFIERS=@im=ibus
# export ARCHFLAGS="-arch x86_64"
export kee=${kee:-$(hostnamectl --static)}
# export kee=${kee:-$(hostnamectl --static)}
export kee=${kee:-$(hostname -s)}
SSH_KEY_PATH="$HOME/.ssh/$kee"
eval $(TERM=xterm-kitty dircolors)
# export DOCKER_HOST=unix:///run/podman/podman.sock
# rootless
export DOCKER_HOST=unix://$XDG_RUNTIME_DIR/podman/podman.sock