add tmux conffigs, guards in atuin and uv

This commit is contained in:
2026-10-20 09:42:55 +01:00
parent 7fc83bc288
commit 075be0999b
+12 -5
View File
@@ -165,18 +165,20 @@ alias cdi='zi'
ZSHRC_EOF
# ============================================================
# tmux — default shell to zsh
# tmux — default shell to zsh, vi mode
# ============================================================
echo "=== tmux default shell ==="
echo "=== tmux config ==="
TMUX_CONF="$HOME/.tmux.conf"
TOUCH_TMUX=0
if [[ ! -f "$TMUX_CONF" ]]; then
touch "$TMUX_CONF"
TOUCH_TMUX=1
fi
if ! grep -qF 'set-option -g default-shell' "$TMUX_CONF"; then
printf 'set-option -g default-shell %s\n' "$(which zsh)" >> "$TMUX_CONF"
fi
if ! grep -qF 'set-window-option -g mode-keys vi' "$TMUX_CONF"; then
printf 'set-window-option -g mode-keys vi\n' >> "$TMUX_CONF"
fi
tmux source-file "$TMUX_CONF" 2>/dev/null || true
# ============================================================
# Add user to libvirt groups
@@ -236,7 +238,12 @@ if [[ "$JUST_NEEDS_INSTALL" -eq 1 ]]; then
"$HOME/.cargo/bin/cargo" install just --version "${JUST_VERSION}" --locked --force
fi
# ============================================================
# uv
# ============================================================
if ! command -v uv >/dev/null 2>&1; then
cargo install --locked uv
fi
# ============================================================
# fzf
@@ -273,7 +280,7 @@ fi
# atuin
# ============================================================
echo "=== atuin ==="
if [[ ! -x "$HOME/.local/bin/atuin" ]]; then
if [[ ! -x "$HOME/.atuin/bin/atuin" ]]; then
curl --proto '=https' --tlsv1.2 -LsSf https://setup.atuin.sh | sh
else
echo "atuin already installed, skipping."