From 84b6e74e7b42763a8e2b55c2f2d860f226b56636 Mon Sep 17 00:00:00 2001 From: Asmir A Date: Fri, 12 Apr 2024 21:48:25 +0200 Subject: [PATCH] home/zsh: format, remove dead code --- home/zsh.nix | 55 ++++++++++++++++++++++++---------------------------- 1 file changed, 25 insertions(+), 30 deletions(-) diff --git a/home/zsh.nix b/home/zsh.nix index e4c7067..ed61141 100644 --- a/home/zsh.nix +++ b/home/zsh.nix @@ -1,9 +1,4 @@ -{ - config, - lib, - pkgs, - ... -}: { +{pkgs, ...}: { programs.z-lua = { enableAliases = true; enableZshIntegration = true; @@ -77,36 +72,36 @@ envExtra = ''''; initExtra = '' - # binds - bindkey '^K' fzf-file-widget + # binds + bindkey '^K' fzf-file-widget - # options - setopt nobeep - setopt nopromptcr - setopt c_bases - setopt completeinword - setopt completealiases - setopt notify + # options + setopt nobeep + setopt nopromptcr + setopt c_bases + setopt completeinword + setopt completealiases + setopt notify - # - RPS1="" + # + RPS1="" - # - function chpwd() { - ls; - } + # + function chpwd() { + ls; + } - eval "$(direnv hook zsh)" - zstyle ':completion:*' matcher-list 'm:{a-z}={A-Za-z}' + eval "$(direnv hook zsh)" + zstyle ':completion:*' matcher-list 'm:{a-z}={A-Za-z}' - if [[ -n "$PS1" ]] && [[ -z "$TMUX" ]] && [[ -n "$SSH_CONNECTION" ]]; then - TMUX_EXE="${pkgs.tmux}/bin/tmux" - systemd-run --scope --user $TMUX_EXE attach-session -t $USER || systemd-run --scope --user $TMUX_EXE new-session -s $USER - fi + if [[ -n "$PS1" ]] && [[ -z "$TMUX" ]] && [[ -n "$SSH_CONNECTION" ]]; then + TMUX_EXE="${pkgs.tmux}/bin/tmux" + systemd-run --scope --user $TMUX_EXE attach-session -t $USER || systemd-run --scope --user $TMUX_EXE new-session -s $USER + fi - if [[ -n "$BUBBLEWRAP_DIR" ]]; then - RPS1="{{$BUBBLEWRAP_DIR}}" - fi + if [[ -n "$BUBBLEWRAP_DIR" ]]; then + RPS1="{{$BUBBLEWRAP_DIR}}" + fi ''; }; }