about summary refs log tree commit diff
path: root/users/grfn/system/home/modules/shell.nix
diff options
context:
space:
mode:
authorGriffin Smith <grfn@gws.fyi>2022-05-31T19·34-0400
committerclbot <clbot@tvl.fyi>2022-05-31T19·38+0000
commit8851075c2764fecde2a112815d7958d5d29fb406 (patch)
tree3d145c5855117324d33382b6c9d75b8e5c606701 /users/grfn/system/home/modules/shell.nix
parentfb228861656a7dff2d3619a7b4b70bce26152b23 (diff)
feat(grfn/system): Resuscitate roswell r/4195
Resuscitate the configuration for roswell, the semi-portable
configuration I use for ec2 development boxes. Lots of the changes here
are trying to get Tramp working.

Change-Id: I2dc2fd1d9aa76e145fa3f3f847af761cb652ab47
Reviewed-on: https://cl.tvl.fyi/c/depot/+/5798
Reviewed-by: grfn <grfn@gws.fyi>
Autosubmit: grfn <grfn@gws.fyi>
Tested-by: BuildkiteCI
Diffstat (limited to 'users/grfn/system/home/modules/shell.nix')
-rw-r--r--users/grfn/system/home/modules/shell.nix50
1 files changed, 27 insertions, 23 deletions
diff --git a/users/grfn/system/home/modules/shell.nix b/users/grfn/system/home/modules/shell.nix
index ed82292b0a..8d8d5884ce 100644
--- a/users/grfn/system/home/modules/shell.nix
+++ b/users/grfn/system/home/modules/shell.nix
@@ -68,7 +68,6 @@ in
   home.packages = with pkgs; [
     zsh
     autojump
-    ntfy
   ];
 
   home.sessionVariables = {
@@ -133,6 +132,12 @@ in
       };
     }];
 
+    initExtraFirst = ''
+      if [[ "$TERM" = "dumb" ]]; then
+        return
+      fi
+    '';
+
     initExtraBeforeCompInit = ''
       zstyle ':completion:*' completer _complete _ignored _correct _approximate
       zstyle ':completion:*' matcher-list \'\' 'm:{[:lower:]}={[:upper:]} m:{[:lower:][:upper:]}={[:upper:][:lower:]} r:|[._- :]=** r:|=**' 'l:|=* r:|=*'
@@ -145,33 +150,32 @@ in
     '';
 
     initExtra = ''
-      source ${./zshrc}
-      source ${pkgs.fetchFromGitHub {
-        owner = "zsh-users";
-        repo = "zsh-syntax-highlighting";
-        rev = "7678a8a22780141617f809002eeccf054bf8f448";
-        sha256 = "0xh4fbd54kvwwpqvabk8lpw7m80phxdzrd75q3y874jw0xx1a9q6";
-      }}/zsh-syntax-highlighting.zsh
-      source ${pkgs.autojump}/share/autojump/autojump.zsh
-      source ${pkgs.fetchFromGitHub {
-        owner = "chisui";
-        repo = "zsh-nix-shell";
-        rev = "a65382a353eaee5a98f068c330947c032a1263bb";
-        sha256 = "0l41ac5b7p8yyjvpfp438kw7zl9dblrpd7icjg1v3ig3xy87zv0n";
-      }}/nix-shell.plugin.zsh
-
-      eval "$(${pkgs.ntfy}/bin/ntfy shell-integration)"
-
-      export RPS1=""
-      autoload -U promptinit; promptinit
-      prompt pure
+      if [[ "$TERM" != "dumb" ]]; then
+        source ${./zshrc}
+        source ${pkgs.fetchFromGitHub {
+          owner = "zsh-users";
+          repo = "zsh-syntax-highlighting";
+          rev = "7678a8a22780141617f809002eeccf054bf8f448";
+          sha256 = "0xh4fbd54kvwwpqvabk8lpw7m80phxdzrd75q3y874jw0xx1a9q6";
+        }}/zsh-syntax-highlighting.zsh
+        source ${pkgs.autojump}/share/autojump/autojump.zsh
+        source ${pkgs.fetchFromGitHub {
+          owner = "chisui";
+          repo = "zsh-nix-shell";
+          rev = "a65382a353eaee5a98f068c330947c032a1263bb";
+          sha256 = "0l41ac5b7p8yyjvpfp438kw7zl9dblrpd7icjg1v3ig3xy87zv0n";
+        }}/nix-shell.plugin.zsh
+
+        export RPS1=""
+        autoload -U promptinit; promptinit
+        prompt pure
+      fi
 
       if [[ "$TERM" == "dumb" ]]; then
         unsetopt zle
         unsetopt prompt_cr
         unsetopt prompt_subst
-        unfunction precmd
-        unfunction preexec
+        unset zle_bracketed_paste
         export PS1='$ '
       fi
     '';