tree-wide change. seperated config from 'real' modles.
This commit is contained in:
		
							parent
							
								
									3eee4e105d
								
							
						
					
					
						commit
						a0c1ad0beb
					
				
					 59 changed files with 377 additions and 424 deletions
				
			
		
							
								
								
									
										38
									
								
								configs/home-manager/beets.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										38
									
								
								configs/home-manager/beets.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,38 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  programs.beets = {
 | 
			
		||||
    enable = true;
 | 
			
		||||
    settings = {
 | 
			
		||||
      directory = "~/Music";
 | 
			
		||||
      library = "~/Music/library.db";
 | 
			
		||||
      import = {
 | 
			
		||||
        move = true;
 | 
			
		||||
        write = true;
 | 
			
		||||
      };
 | 
			
		||||
      plugins = [
 | 
			
		||||
        "edit"
 | 
			
		||||
        "fetchart"
 | 
			
		||||
        "chroma"
 | 
			
		||||
        "thumbnails"
 | 
			
		||||
        "replaygain"
 | 
			
		||||
        "mbsync"
 | 
			
		||||
        "fuzzy"
 | 
			
		||||
        "duplicates"
 | 
			
		||||
        "badfiles"
 | 
			
		||||
        "fromfilename"
 | 
			
		||||
      ];
 | 
			
		||||
      replaygain = {
 | 
			
		||||
        auto = false;
 | 
			
		||||
        backend = "ffmpeg";
 | 
			
		||||
      };
 | 
			
		||||
      asciify_paths = true;
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
  home.packages = with pkgs; [
 | 
			
		||||
    ffmpeg
 | 
			
		||||
  ];
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										13
									
								
								configs/home-manager/btop.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										13
									
								
								configs/home-manager/btop.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,13 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  programs.btop = {
 | 
			
		||||
    enable = true;
 | 
			
		||||
    settings = {
 | 
			
		||||
      vim_keys = true;
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										31
									
								
								configs/home-manager/common.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										31
									
								
								configs/home-manager/common.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,31 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  home.stateVersion = "23.11"; # Please read the comment before changing.
 | 
			
		||||
 | 
			
		||||
  # Let Home Manager install and manage itself on non-nixos systems.
 | 
			
		||||
  programs.home-manager.enable = config.targets.genericLinux.enable;
 | 
			
		||||
 | 
			
		||||
  # enable flakes on non-nixos systems
 | 
			
		||||
  nix =
 | 
			
		||||
    lib.mkIf config.targets.genericLinux.enable
 | 
			
		||||
    {
 | 
			
		||||
      package = pkgs.nix;
 | 
			
		||||
      settings = {
 | 
			
		||||
        experimental-features = ["nix-command" "flakes"];
 | 
			
		||||
        max-jobs = "auto";
 | 
			
		||||
      };
 | 
			
		||||
      gc = {
 | 
			
		||||
        automatic = true;
 | 
			
		||||
        frequency = "weekly";
 | 
			
		||||
        options = "--delete-older-than 30d";
 | 
			
		||||
      };
 | 
			
		||||
    };
 | 
			
		||||
  imports = [
 | 
			
		||||
    ../../modules/hostopts.nix
 | 
			
		||||
    ../../modules/home-manager
 | 
			
		||||
  ];
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										11
									
								
								configs/home-manager/direnv.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										11
									
								
								configs/home-manager/direnv.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,11 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pgks,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  programs.direnv = {
 | 
			
		||||
    enable = true;
 | 
			
		||||
    nix-direnv.enable = true;
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										54
									
								
								configs/home-manager/dunst.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										54
									
								
								configs/home-manager/dunst.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,54 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  services = {
 | 
			
		||||
    dunst.enable = true;
 | 
			
		||||
    dunst.settings = {
 | 
			
		||||
      global = {
 | 
			
		||||
        font = "Fira Code";
 | 
			
		||||
        follow = "keyboard";
 | 
			
		||||
        origin = "top-right";
 | 
			
		||||
        transparency = 20;
 | 
			
		||||
        padding = 6;
 | 
			
		||||
        horizontal_padding = 6;
 | 
			
		||||
      };
 | 
			
		||||
      urgency_low = {
 | 
			
		||||
        # IMPORTANT: colors have to be defined in quotation marks.
 | 
			
		||||
        # Otherwise the "#" and following would be interpreted as a comment.
 | 
			
		||||
        frame_color = "#3B7C87";
 | 
			
		||||
        foreground = "#3B7C87";
 | 
			
		||||
        highlight = "#3B7C87";
 | 
			
		||||
        background = "#191311";
 | 
			
		||||
        #background = "#2B313C"
 | 
			
		||||
        timeout = 4;
 | 
			
		||||
        # Icon for notifications with low urgency, uncomment to enable
 | 
			
		||||
        #default_icon = /path/to/icon
 | 
			
		||||
      };
 | 
			
		||||
 | 
			
		||||
      urgency_normal = {
 | 
			
		||||
        frame_color = "#5B8234";
 | 
			
		||||
        foreground = "#5B8234";
 | 
			
		||||
        highlight = "#5B8234";
 | 
			
		||||
        background = "#191311";
 | 
			
		||||
        #background = "#2B313C"
 | 
			
		||||
        timeout = 6;
 | 
			
		||||
        # Icon for notifications with normal urgency, uncomment to enable
 | 
			
		||||
        #default_icon = /path/to/icon
 | 
			
		||||
      };
 | 
			
		||||
 | 
			
		||||
      urgency_critical = {
 | 
			
		||||
        frame_color = "#B7472A";
 | 
			
		||||
        foreground = "#B7472A";
 | 
			
		||||
        highlight = "#B7472A";
 | 
			
		||||
        background = "#191311";
 | 
			
		||||
        #background = "#2B313C"
 | 
			
		||||
        timeout = 8;
 | 
			
		||||
        # Icon for notifications with critical urgency, uncomment to enable
 | 
			
		||||
        #default_icon = /path/to/icon
 | 
			
		||||
      };
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										37
									
								
								configs/home-manager/email.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										37
									
								
								configs/home-manager/email.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,37 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  home.packages = with pkgs; [
 | 
			
		||||
    w3m
 | 
			
		||||
  ];
 | 
			
		||||
 | 
			
		||||
  programs.aerc = {
 | 
			
		||||
    enable = true;
 | 
			
		||||
    extraConfig = {
 | 
			
		||||
      general.unsafe-accounts-conf = true;
 | 
			
		||||
      viwer = {
 | 
			
		||||
        pager = "less";
 | 
			
		||||
      };
 | 
			
		||||
      filters = {
 | 
			
		||||
        "text/plain" = "colorize";
 | 
			
		||||
        "text/html" = "html | colorize";
 | 
			
		||||
      };
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
 | 
			
		||||
  programs.himalaya.enable = true;
 | 
			
		||||
 | 
			
		||||
  accounts.email.accounts.gmail = {
 | 
			
		||||
    address = "gabevenberg@gmail.com";
 | 
			
		||||
    primary = true;
 | 
			
		||||
    flavor = "gmail.com";
 | 
			
		||||
    passwordCommand = "cat ~/keys/plaintext/gmail";
 | 
			
		||||
    realName = "Gabe Venberg";
 | 
			
		||||
 | 
			
		||||
    himalaya.enable = true;
 | 
			
		||||
    aerc.enable = true;
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										16
									
								
								configs/home-manager/feh.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										16
									
								
								configs/home-manager/feh.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,16 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  programs.feh.enable = true;
 | 
			
		||||
 | 
			
		||||
  programs.nushell.extraConfig = ''
 | 
			
		||||
    # display a slideshow of all pics in a directory, recursively
 | 
			
		||||
    def slideshow [delay: int = 10] {
 | 
			
		||||
        feh --full-screen --randomize --auto-zoom --recursive --slideshow-delay $delay
 | 
			
		||||
    }
 | 
			
		||||
  '';
 | 
			
		||||
  programs.zsh.shellAliases. slideshow = "feh --full-screen --randomize --auto-zoom --recursive --slideshow-delay";
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										14
									
								
								configs/home-manager/gpg.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										14
									
								
								configs/home-manager/gpg.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,14 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  programs.gpg.enable = true;
 | 
			
		||||
 | 
			
		||||
  services.gpg-agent = {
 | 
			
		||||
    enable = true;
 | 
			
		||||
    enableSshSupport = true;
 | 
			
		||||
    pinentryPackage = lib.mkDefault pkgs.pinentry-tty;
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										41
									
								
								configs/home-manager/irssi.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										41
									
								
								configs/home-manager/irssi.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,41 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  options.user.irssi.enable = lib.mkEnableOption "enable irssi";
 | 
			
		||||
  config = lib.mkIf config.user.irssi.enable {
 | 
			
		||||
    programs.irssi = {
 | 
			
		||||
      enable = true;
 | 
			
		||||
      networks = {
 | 
			
		||||
        liberachat = {
 | 
			
		||||
          nick = "toric";
 | 
			
		||||
          server = {
 | 
			
		||||
            address = "irc.libera.chat";
 | 
			
		||||
            port = 6697;
 | 
			
		||||
            autoConnect = true;
 | 
			
		||||
            ssl = {
 | 
			
		||||
              enable = true;
 | 
			
		||||
              certificateFile = "${config.home.homeDirectory}/keys/certs/irc.pem";
 | 
			
		||||
              verify = true;
 | 
			
		||||
            };
 | 
			
		||||
          };
 | 
			
		||||
          channels = {
 | 
			
		||||
            libera.autoJoin = true;
 | 
			
		||||
            linux.autoJoin = true;
 | 
			
		||||
            programming.autoJoin = true;
 | 
			
		||||
            rust.autoJoin = true;
 | 
			
		||||
            nixos.autoJoin = true;
 | 
			
		||||
            git.autoJoin = true;
 | 
			
		||||
            neovim.autoJoin = true;
 | 
			
		||||
            kernel.autoJoin = true;
 | 
			
		||||
            hardware.autoJoin = true;
 | 
			
		||||
            lobsters.autoJoin = true;
 | 
			
		||||
            gamingonlinux.autoJoin = true;
 | 
			
		||||
          };
 | 
			
		||||
        };
 | 
			
		||||
      };
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										18
									
								
								configs/home-manager/kitty.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								configs/home-manager/kitty.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,18 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  programs.kitty = {
 | 
			
		||||
    enable = true;
 | 
			
		||||
    font = {
 | 
			
		||||
      package = pkgs.fira-code-nerdfont;
 | 
			
		||||
      name = "FiraCode Nerd Font";
 | 
			
		||||
    };
 | 
			
		||||
    theme = "Gruvbox Dark";
 | 
			
		||||
    settings = {
 | 
			
		||||
      background_opacity = "0.8";
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										65
									
								
								configs/home-manager/mpd.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										65
									
								
								configs/home-manager/mpd.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,65 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  services.mpd = {
 | 
			
		||||
    enable = true;
 | 
			
		||||
    musicDirectory = "${config.home.homeDirectory}/Music";
 | 
			
		||||
    network.startWhenNeeded = true;
 | 
			
		||||
    playlistDirectory = "${config.services.mpd.musicDirectory}/.mpd/playlists";
 | 
			
		||||
    extraConfig = ''
 | 
			
		||||
      restore_paused "yes"
 | 
			
		||||
      auto_update "yes"
 | 
			
		||||
      replaygain "auto"
 | 
			
		||||
      follow_outside_symlinks "yes"
 | 
			
		||||
 | 
			
		||||
      #for ncmpcpp visualizer
 | 
			
		||||
      audio_output {
 | 
			
		||||
          type "fifo"
 | 
			
		||||
          name "Visualizer feed"
 | 
			
		||||
          path "/tmp/mpd.fifo"
 | 
			
		||||
          format "44100:16:2"
 | 
			
		||||
      }
 | 
			
		||||
      audio_output {
 | 
			
		||||
        type "pipewire"
 | 
			
		||||
        name "PipeWire Sound Server"
 | 
			
		||||
      }
 | 
			
		||||
    '';
 | 
			
		||||
  };
 | 
			
		||||
 | 
			
		||||
  services.mpd-mpris.enable = true;
 | 
			
		||||
 | 
			
		||||
  programs.ncmpcpp = {
 | 
			
		||||
    enable = true;
 | 
			
		||||
    package = pkgs.ncmpcpp.override {visualizerSupport = true;};
 | 
			
		||||
    settings = {
 | 
			
		||||
      visualizer_data_source = "/tmp/mpd.fifo";
 | 
			
		||||
      visualizer_output_name = "Visualizer feed";
 | 
			
		||||
      visualizer_in_stereo = "yes";
 | 
			
		||||
      visualizer_type = "spectrum";
 | 
			
		||||
      visualizer_fps = 60;
 | 
			
		||||
      visualizer_autoscale = "no";
 | 
			
		||||
      visualizer_look = "●▮";
 | 
			
		||||
      visualizer_color = "blue, cyan, green, yellow, magenta, red";
 | 
			
		||||
 | 
			
		||||
      ##
 | 
			
		||||
      ## Note: The next few visualization options apply to the spectrum visualizer.
 | 
			
		||||
      ##
 | 
			
		||||
      visualizer_spectrum_smooth_look = "yes";
 | 
			
		||||
 | 
			
		||||
      ## A value between 1 and 5 inclusive. Specifying a larger value makes the
 | 
			
		||||
      ## visualizer look at a larger slice of time, which results in less jumpy
 | 
			
		||||
      ## visualizer output.
 | 
			
		||||
      visualizer_spectrum_dft_size = 2;
 | 
			
		||||
      visualizer_spectrum_gain = 10;
 | 
			
		||||
      visualizer_spectrum_hz_min = 20;
 | 
			
		||||
      visualizer_spectrum_hz_max = 20000;
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
 | 
			
		||||
  home.packages = with pkgs; [
 | 
			
		||||
    mpc-cli
 | 
			
		||||
  ];
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										9
									
								
								configs/home-manager/nextcloud.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								configs/home-manager/nextcloud.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,9 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  services.nextcloud-client.enable = true;
 | 
			
		||||
  services.gnome-keyring.enable = true;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										44
									
								
								configs/home-manager/nushell/completions/just-completions.nu
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										44
									
								
								configs/home-manager/nushell/completions/just-completions.nu
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,44 @@
 | 
			
		|||
def "nu-complete just recipes" [] {
 | 
			
		||||
    ^just --unsorted --dump --dump-format json
 | 
			
		||||
        | from json
 | 
			
		||||
        | get recipes
 | 
			
		||||
        | transpose k v
 | 
			
		||||
        | each {|x|
 | 
			
		||||
            {
 | 
			
		||||
                value: $x.k,
 | 
			
		||||
                description: ( $x.v.parameters
 | 
			
		||||
                             | each {|y|
 | 
			
		||||
                                    if ($y.default|is-empty) {
 | 
			
		||||
                                        $y.name
 | 
			
		||||
                                    } else {
 | 
			
		||||
                                        $'($y.name)="($y.default)"'
 | 
			
		||||
                                    }
 | 
			
		||||
                                }
 | 
			
		||||
                             | str join ' '
 | 
			
		||||
                             )
 | 
			
		||||
            }
 | 
			
		||||
        }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def "nu-complete just args" [context: string, offset: int] {
 | 
			
		||||
    let r = ($context | split row ' ')
 | 
			
		||||
    ^just -u --dump --dump-format json
 | 
			
		||||
        | from json
 | 
			
		||||
        | get recipes
 | 
			
		||||
        | get ($r.1)
 | 
			
		||||
        | get body
 | 
			
		||||
        | each {|x| {description: ($x | get 0) }}
 | 
			
		||||
        | prepend ''
 | 
			
		||||
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
export def just [
 | 
			
		||||
    recipes?: string@"nu-complete just recipes"
 | 
			
		||||
    ...args: any@"nu-complete just args"
 | 
			
		||||
] {
 | 
			
		||||
    if ($recipes | is-empty) {
 | 
			
		||||
        ^just
 | 
			
		||||
    } else {
 | 
			
		||||
        ^just $recipes ...$args
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										65
									
								
								configs/home-manager/nushell/completions/make-completions.nu
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										65
									
								
								configs/home-manager/nushell/completions/make-completions.nu
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,65 @@
 | 
			
		|||
def "nu-complete make" [] {
 | 
			
		||||
    ls 
 | 
			
		||||
    | find --ignore-case makefile
 | 
			
		||||
    | open $in.0.name
 | 
			
		||||
    | lines 
 | 
			
		||||
    | find ':' 
 | 
			
		||||
    | where ($it | str starts-with '.') == false 
 | 
			
		||||
    | split column ' ' 
 | 
			
		||||
    | get column1 
 | 
			
		||||
    | find ':' 
 | 
			
		||||
    | str replace ':' ''
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def "nu-complete make jobs" [] {
 | 
			
		||||
    seq 1 (sys | get cpu | length)
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def "nu-complete make files" [] {
 | 
			
		||||
    ls **/* | where type == file | get name
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def "nu-complete make dirs" [] {
 | 
			
		||||
    ls **/* | where type == dir | get name
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
export extern "make" [
 | 
			
		||||
    command?: string@"nu-complete make"
 | 
			
		||||
    --always-make(-B)                                 # Unconditionally make all targets.
 | 
			
		||||
    --directory(-C): string@"nu-complete make dirs"   # Change to DIRECTORY before doing anything.
 | 
			
		||||
    --debug(-d)                                       # Print various types of debugging information.
 | 
			
		||||
    --environment-overrides(-e)                       # Environment variables override makefiles.
 | 
			
		||||
    --eval(-E): string                                # Evaluate STRING as a makefile statement.
 | 
			
		||||
    --file(-f)                                        # Read FILE as a makefile.
 | 
			
		||||
    --help(-h)                                        # Print this message and exit.
 | 
			
		||||
    --ignore-errors(-i)                               # Ignore errors from recipes.
 | 
			
		||||
    --include-dir(-I): string@"nu-complete make dirs" # Search DIRECTORY for included makefiles.
 | 
			
		||||
    --jobs(-j): int@"nu-complete make jobs"           # Allow N jobs at once; infinite jobs with no arg.
 | 
			
		||||
    --keep-going(-k)                                  # Keep going when some targets can't be made.
 | 
			
		||||
    --load-average(-l): int@"nu-complete make jobs"   # Don't start multiple jobs unless load is below N.
 | 
			
		||||
    --check-symlink-times(-L)                         # Use the latest mtime between symlinks and target.
 | 
			
		||||
    --just-print(-n)                                  # Don't actually run any recipe; just print them.
 | 
			
		||||
    --dry-run
 | 
			
		||||
    --recon
 | 
			
		||||
    --assume-old: string@"nu-complete make files"     # Consider FILE to be very old and don't remake it.
 | 
			
		||||
    --old-file(-o): string@"nu-complete make files"
 | 
			
		||||
    --output-sync(-O)                                 # Synchronize output of parallel jobs by TYPE.
 | 
			
		||||
    --print-data-base(-p)                             # Print make's internal database.
 | 
			
		||||
    --question(-q)                                    # Run no recipe; exit status says if up to date.
 | 
			
		||||
    --no-builtin-rules(-r)                            # Disable the built-in implicit rules.
 | 
			
		||||
    --no-builtin-variables(-R)                        # Disable the built-in variable settings.
 | 
			
		||||
    --silent(-s)                                      # Don't echo recipes.
 | 
			
		||||
    --quiet
 | 
			
		||||
    --no-silent                                       # Echo recipes (disable --silent mode).
 | 
			
		||||
    --stop(-S)                                        # Turns off -k.
 | 
			
		||||
    --no-keep-going
 | 
			
		||||
    --touch(-t)                                       # Touch targets instead of remaking them.
 | 
			
		||||
    --trace                                           # Print tracing information.
 | 
			
		||||
    --version(-v)                                     # Print the version number of make and exit.
 | 
			
		||||
    --print-directory(-w)                             # Print the current directory.
 | 
			
		||||
    --no-print-directory                              # Turn off -w, even if it was turned on implicitly.
 | 
			
		||||
    --what-if(-W): string@"nu-complete make files"    # Consider FILE to be infinitely new.
 | 
			
		||||
    --new-file: string@"nu-complete make files"
 | 
			
		||||
    --assume-new: string@"nu-complete make files"
 | 
			
		||||
    --warn-undefined-variables                        # Warn when an undefined variable is referenced.
 | 
			
		||||
]
 | 
			
		||||
							
								
								
									
										2
									
								
								configs/home-manager/nushell/completions/mod.nu
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										2
									
								
								configs/home-manager/nushell/completions/mod.nu
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,2 @@
 | 
			
		|||
export use just-completions.nu *
 | 
			
		||||
export use make-completions.nu *
 | 
			
		||||
							
								
								
									
										65
									
								
								configs/home-manager/nushell/config.nu
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										65
									
								
								configs/home-manager/nushell/config.nu
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,65 @@
 | 
			
		|||
# Nushell Config File
 | 
			
		||||
#
 | 
			
		||||
# version = "0.91.0"
 | 
			
		||||
 | 
			
		||||
$env.config = {
 | 
			
		||||
    history: {
 | 
			
		||||
        file_format: "sqlite" # "sqlite" or "plaintext"
 | 
			
		||||
    }
 | 
			
		||||
    completions: {
 | 
			
		||||
        algorithm: "fuzzy"    # prefix or fuzzy
 | 
			
		||||
    }
 | 
			
		||||
    filesize: {
 | 
			
		||||
        metric: true # true => KB, MB, GB (ISO standard), false => KiB, MiB, GiB (Windows standard)
 | 
			
		||||
        format: "auto" # b, kb, kib, mb, mib, gb, gib, tb, tib, pb, pib, eb, eib, auto
 | 
			
		||||
    }
 | 
			
		||||
    cursor_shape: {
 | 
			
		||||
        emacs: line # block, underscore, line, blink_block, blink_underscore, blink_line, inherit to skip setting cursor shape (line is the default)
 | 
			
		||||
        vi_insert: line # block, underscore, line, blink_block, blink_underscore, blink_line, inherit to skip setting cursor shape (block is the default)
 | 
			
		||||
        vi_normal: blink_block # block, underscore, line, blink_block, blink_underscore, blink_line, inherit to skip setting cursor shape (underscore is the default)
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    edit_mode: vi # emacs, vi
 | 
			
		||||
    shell_integration: true # enables terminal shell integration. Off by default, as some terminals have issues with this.
 | 
			
		||||
    render_right_prompt_on_last_line: false # true or false to enable or disable right prompt to be rendered on last line of the prompt.
 | 
			
		||||
    # enables keyboard enhancement protocol implemented by kitty console, only if your terminal support this. 
 | 
			
		||||
    # Zellij does not modify the term var, so we have to special-case it.
 | 
			
		||||
    use_kitty_protocol: ($env.TERM == 'xterm-kitty' and $env.ZELLIJ? == null)
 | 
			
		||||
    highlight_resolved_externals: true # true enables highlighting of external commands in the repl resolved by which.
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
alias please = sudo (history | last | get command)
 | 
			
		||||
alias la = ls -a
 | 
			
		||||
alias ll = ls -l
 | 
			
		||||
alias lla = ls -la
 | 
			
		||||
alias pyactivate = overlay use ./.venv/bin/activate.nu
 | 
			
		||||
alias tmux = tmux -u
 | 
			
		||||
# converts all .doc and .docx files in the local directory to pdfs using libreoffice
 | 
			
		||||
alias doc2pdf = loffice --convert-to pdf --headless *.docx
 | 
			
		||||
#common options for sshfs
 | 
			
		||||
alias sshmnt = sshfs -o idmap=user,compression=no,reconnect,follow_symlinks,dir_cache=yes,ServerAliveInterval=15
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
#look up something on cheat.sh
 | 
			
		||||
def cheat [query: string] {
 | 
			
		||||
    curl $"cheat.sh/($query)"
 | 
			
		||||
}
 | 
			
		||||
#look up the weather
 | 
			
		||||
def wttr [
 | 
			
		||||
    location?: string
 | 
			
		||||
    --format (-f): string
 | 
			
		||||
] {
 | 
			
		||||
    http get $"https://wttr.in/($location)?format=($format)"
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
# parses git log into a nushell table.
 | 
			
		||||
def --wrapped git-log [...rest] {
 | 
			
		||||
    git log --pretty=%h»¦«%H»¦«%s»¦«%aN»¦«%aE»¦«%aD ...$rest | lines | split column "»¦«" commit full-commit subject name email date | upsert date {|d| $d.date | into datetime}
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
# lists all the authors and how many commits they made in a histogram
 | 
			
		||||
def git-authors [] {
 | 
			
		||||
    git-log --all | select name date | histogram name
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
use completions *
 | 
			
		||||
							
								
								
									
										40
									
								
								configs/home-manager/nushell/default.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										40
									
								
								configs/home-manager/nushell/default.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,40 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  lib,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  home.file = {
 | 
			
		||||
    ".config/nushell/completions".source = ./completions;
 | 
			
		||||
  };
 | 
			
		||||
 | 
			
		||||
  programs = {
 | 
			
		||||
    #sessionVariables, sessionPath and shellAliases are not applied to nushell.
 | 
			
		||||
    nushell = {
 | 
			
		||||
      enable = true;
 | 
			
		||||
      configFile.source = ./config.nu;
 | 
			
		||||
      envFile.source = ./env.nu;
 | 
			
		||||
    };
 | 
			
		||||
 | 
			
		||||
    yazi.enableNushellIntegration = true;
 | 
			
		||||
    zoxide.enableNushellIntegration = true;
 | 
			
		||||
    starship.enableNushellIntegration = true;
 | 
			
		||||
    eza.enableNushellIntegration = true;
 | 
			
		||||
    carapace = {
 | 
			
		||||
      enable = true;
 | 
			
		||||
      enableNushellIntegration = true;
 | 
			
		||||
    };
 | 
			
		||||
    direnv.enableNushellIntegration = true;
 | 
			
		||||
  };
 | 
			
		||||
  services = {
 | 
			
		||||
    gpg-agent.enableNushellIntegration = true;
 | 
			
		||||
    pueue = {
 | 
			
		||||
      enable = true;
 | 
			
		||||
      settings = {
 | 
			
		||||
        daemon = {
 | 
			
		||||
          default_parallel_tasks = 5;
 | 
			
		||||
        };
 | 
			
		||||
      };
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										27
									
								
								configs/home-manager/nushell/env.nu
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										27
									
								
								configs/home-manager/nushell/env.nu
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,27 @@
 | 
			
		|||
# Nushell Environment Config File
 | 
			
		||||
#
 | 
			
		||||
# version = "0.91.0"
 | 
			
		||||
# The prompt indicators are environmental variables that represent
 | 
			
		||||
# the state of the prompt
 | 
			
		||||
$env.PROMPT_INDICATOR = {|| "> " }
 | 
			
		||||
$env.PROMPT_INDICATOR_VI_INSERT = {|| "> " }
 | 
			
		||||
$env.PROMPT_INDICATOR_VI_NORMAL = {|| ": " }
 | 
			
		||||
$env.PROMPT_MULTILINE_INDICATOR = {|| "::: " }
 | 
			
		||||
 | 
			
		||||
# home managers path, shell aliases, and env vars are not applied to nushell.
 | 
			
		||||
use std "path add"
 | 
			
		||||
# $env.PATH = ($env.PATH | split row (char esep))
 | 
			
		||||
path add ($env.HOME | path join ".cargo" "bin")
 | 
			
		||||
path add ($env.HOME | path join ".local" "bin")
 | 
			
		||||
path add ($env.HOME | path join ".nix-profile" "bin")
 | 
			
		||||
path add ('/opt')
 | 
			
		||||
$env.PATH = ($env.PATH | uniq)
 | 
			
		||||
 | 
			
		||||
$env.PIPENV_VENV_IN_PROJECT = 1
 | 
			
		||||
$env.POETRY_VIRTUALENVS_IN_PROJECT = 1
 | 
			
		||||
$env.XDG_DATA_HOME = ( $env.HOME | path join ".local" "share" )
 | 
			
		||||
 | 
			
		||||
$env.NU_LIB_DIRS = [
 | 
			
		||||
    ...
 | 
			
		||||
    $nu.default-config-dir
 | 
			
		||||
]
 | 
			
		||||
							
								
								
									
										27
									
								
								configs/home-manager/nushell/scripts/ultimate_extractor.nu
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										27
									
								
								configs/home-manager/nushell/scripts/ultimate_extractor.nu
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,27 @@
 | 
			
		|||
# Function to extract archives with different extensions.
 | 
			
		||||
export def extract [name:string] {
 | 
			
		||||
    let handlers = [ 
 | 
			
		||||
        [extension command];
 | 
			
		||||
        ['tar\.bz2|tbz|tbz2' 'tar xvjf']
 | 
			
		||||
        ['tar\.gz|tgz'       'tar xvzf']
 | 
			
		||||
        ['tar\.xz|txz'       'tar xvf']
 | 
			
		||||
        ['tar\.Z'            'tar xvZf']
 | 
			
		||||
        ['bz2'               'bunzip2']
 | 
			
		||||
        ['deb'               'ar x']
 | 
			
		||||
        ['gz'                'gunzip']
 | 
			
		||||
        ['pkg'               'pkgutil --expand']
 | 
			
		||||
        ['rar'               'unrar x']
 | 
			
		||||
        ['tar'               'tar xvf']
 | 
			
		||||
        ['xz'                'xz --decompress']
 | 
			
		||||
        ['zip|war|jar|nupkg' 'unzip']
 | 
			
		||||
        ['Z'                 'uncompress']
 | 
			
		||||
        ['7z'                '7za x']
 | 
			
		||||
    ]
 | 
			
		||||
    let maybe_handler = ($handlers | where $name =~ $'\.(($it.extension))$')
 | 
			
		||||
    if ($maybe_handler | is-empty) {
 | 
			
		||||
        error make { msg: "unsupported file extension" }
 | 
			
		||||
    } else {
 | 
			
		||||
        let handler = ($maybe_handler | first)
 | 
			
		||||
        nu -c ($handler.command + ' ' + $"'($name)'")
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										17
									
								
								configs/home-manager/pass.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										17
									
								
								configs/home-manager/pass.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,17 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  programs.password-store = {
 | 
			
		||||
    enable = true;
 | 
			
		||||
    settings = {
 | 
			
		||||
      PASSWORD_STORE_DIR = "$HOME/keys/password-store";
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
 | 
			
		||||
  programs.nushell.extraEnv = ''
 | 
			
		||||
    $env.PASSWORD_STORE_DIR = ($env.HOME | path join "keys" "password-store")
 | 
			
		||||
  '';
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										18
									
								
								configs/home-manager/picom.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								configs/home-manager/picom.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,18 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  services.picom = {
 | 
			
		||||
    enable = true;
 | 
			
		||||
    # backend = "glx";
 | 
			
		||||
  };
 | 
			
		||||
  xsession.windowManager.i3.config.startup = [
 | 
			
		||||
    {
 | 
			
		||||
      command = "systemctl --user restart picom";
 | 
			
		||||
      always = true;
 | 
			
		||||
      notification = false;
 | 
			
		||||
    }
 | 
			
		||||
  ];
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										13
									
								
								configs/home-manager/rofi.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										13
									
								
								configs/home-manager/rofi.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,13 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  programs.rofi = {
 | 
			
		||||
    enable = true;
 | 
			
		||||
    location = "top";
 | 
			
		||||
    terminal = "kitty";
 | 
			
		||||
    theme = "gruvbox-dark-soft";
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										11
									
								
								configs/home-manager/ssh-agent.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										11
									
								
								configs/home-manager/ssh-agent.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,11 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  services.ssh-agent.enable = true;
 | 
			
		||||
  programs.nushell.extraEnv = ''
 | 
			
		||||
    $env.SSH_AUTH_SOCK = $"($env.XDG_RUNTIME_DIR)/ssh-agent"
 | 
			
		||||
  '';
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										109
									
								
								configs/home-manager/starship.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										109
									
								
								configs/home-manager/starship.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,109 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  programs.starship = {
 | 
			
		||||
    enable = true;
 | 
			
		||||
    settings = {
 | 
			
		||||
      format = lib.concatStrings [
 | 
			
		||||
        "[](color_orange)"
 | 
			
		||||
        "$shell"
 | 
			
		||||
        "$username"
 | 
			
		||||
        "[@](bg:color_orange)"
 | 
			
		||||
        "$hostname"
 | 
			
		||||
        "[ ](bg:color_orange)"
 | 
			
		||||
        "[](bg:color_yellow fg:color_orange)"
 | 
			
		||||
        "$directory"
 | 
			
		||||
        "[](fg:color_yellow bg:color_aqua)"
 | 
			
		||||
        "$git_branch"
 | 
			
		||||
        "$git_status"
 | 
			
		||||
        "[](fg:color_aqua bg:color_blue)"
 | 
			
		||||
        "$git_metrics"
 | 
			
		||||
        "[](fg:color_blue bg:color_bg3)"
 | 
			
		||||
        "$git_commit"
 | 
			
		||||
        "[](fg:color_bg3 bg:color_bg1)"
 | 
			
		||||
        "$time"
 | 
			
		||||
        "[ ](fg:color_bg1)"
 | 
			
		||||
        "$line_break"
 | 
			
		||||
        "$character"
 | 
			
		||||
      ];
 | 
			
		||||
      add_newline = false;
 | 
			
		||||
      palette = "gruvbox_dark";
 | 
			
		||||
      palettes.gruvbox_dark = {
 | 
			
		||||
        color_fg0 = "#fbf1c7";
 | 
			
		||||
        color_bg1 = "#3c3836";
 | 
			
		||||
        color_bg3 = "#665c54";
 | 
			
		||||
        color_blue = "#458588";
 | 
			
		||||
        color_aqua = "#689d6a";
 | 
			
		||||
        color_green = "#98971a";
 | 
			
		||||
        color_orange = "#d65d0e";
 | 
			
		||||
        color_purple = "#b16286";
 | 
			
		||||
        color_red = "#cc241d";
 | 
			
		||||
        color_yellow = "#d79921";
 | 
			
		||||
      };
 | 
			
		||||
      hostname = {
 | 
			
		||||
        ssh_only = false;
 | 
			
		||||
        ssh_symbol = "🌐";
 | 
			
		||||
        format = "[$hostname $ssh_symbol]($style)";
 | 
			
		||||
        style = "bg:color_orange";
 | 
			
		||||
      };
 | 
			
		||||
      shell = {
 | 
			
		||||
        disabled = false;
 | 
			
		||||
        bash_indicator = "$";
 | 
			
		||||
        fish_indicator = "<><";
 | 
			
		||||
        zsh_indicator = "%";
 | 
			
		||||
        nu_indicator = ">";
 | 
			
		||||
        format = "[$indicator ]($style)";
 | 
			
		||||
        style = "bg:color_orange";
 | 
			
		||||
      };
 | 
			
		||||
      fill = {
 | 
			
		||||
        symbol = " ";
 | 
			
		||||
        style = "bg:color_bg3";
 | 
			
		||||
      };
 | 
			
		||||
      username = {
 | 
			
		||||
        show_always = true;
 | 
			
		||||
        style_user = "bg:color_orange fg:color_fg0";
 | 
			
		||||
        style_root = "bg:color_orange fg:color_fg0";
 | 
			
		||||
        format = "[$user]($style)";
 | 
			
		||||
      };
 | 
			
		||||
      directory = {
 | 
			
		||||
        style = "fg:color_fg0 bg:color_yellow";
 | 
			
		||||
        format = "[ $path ]($style)";
 | 
			
		||||
        fish_style_pwd_dir_length = 3;
 | 
			
		||||
        truncation_length = 4;
 | 
			
		||||
        truncation_symbol = "…/";
 | 
			
		||||
      };
 | 
			
		||||
      git_branch = {
 | 
			
		||||
        symbol = "";
 | 
			
		||||
        style = "bg:color_aqua";
 | 
			
		||||
        format = "[[ $symbol $branch ](fg:color_fg0 bg:color_aqua)]($style)";
 | 
			
		||||
      };
 | 
			
		||||
      git_status = {
 | 
			
		||||
        style = "bg:color_aqua";
 | 
			
		||||
        format = "[[($all_status$ahead_behind )](fg:color_fg0 bg:color_aqua)]($style)";
 | 
			
		||||
      };
 | 
			
		||||
      git_metrics = {
 | 
			
		||||
        disabled = false;
 | 
			
		||||
        added_style = "bg:color_blue fg:bold green";
 | 
			
		||||
        deleted_style = "bg:color_blue fg:bold red";
 | 
			
		||||
        format = "([ +$added ]($added_style))([-$deleted ]($deleted_style))";
 | 
			
		||||
      };
 | 
			
		||||
      git_commit = {
 | 
			
		||||
        only_detached = false;
 | 
			
		||||
        tag_disabled = false;
 | 
			
		||||
        format = "[($hash$tag)]($style)";
 | 
			
		||||
        style = "bg:color_bg3";
 | 
			
		||||
      };
 | 
			
		||||
      time = {
 | 
			
		||||
        disabled = false;
 | 
			
		||||
        time_format = "%R";
 | 
			
		||||
        style = "bg:color_bg1";
 | 
			
		||||
        format = "[[  $time ](fg:color_fg0 bg:color_bg1)]($style)";
 | 
			
		||||
      };
 | 
			
		||||
      line_break.disabled = false;
 | 
			
		||||
      character.disabled = false;
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										8
									
								
								configs/home-manager/syncthing.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										8
									
								
								configs/home-manager/syncthing.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,8 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  services.syncthing.enable = true;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										47
									
								
								configs/home-manager/tiny-irc.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										47
									
								
								configs/home-manager/tiny-irc.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,47 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  programs.tiny = {
 | 
			
		||||
    enable = true;
 | 
			
		||||
    settings = {
 | 
			
		||||
      servers = [
 | 
			
		||||
        {
 | 
			
		||||
          addr = "irc.libera.chat";
 | 
			
		||||
          port = 6697;
 | 
			
		||||
          tls = true;
 | 
			
		||||
          realname = "Gabe Venberg";
 | 
			
		||||
          nicks = ["toric"];
 | 
			
		||||
          join = [
 | 
			
		||||
            "#libera"
 | 
			
		||||
            "#linux"
 | 
			
		||||
            "#archlinux"
 | 
			
		||||
            "#nixos"
 | 
			
		||||
            "#neovim"
 | 
			
		||||
            "##programming"
 | 
			
		||||
            "##rust"
 | 
			
		||||
            "#git"
 | 
			
		||||
            "#kernel"
 | 
			
		||||
            "#hardware"
 | 
			
		||||
            "#lobsters"
 | 
			
		||||
            "#gamingonlinux"
 | 
			
		||||
            "##chat"
 | 
			
		||||
          ];
 | 
			
		||||
          sasl = {
 | 
			
		||||
            username = "toric";
 | 
			
		||||
            pem = "${config.home.homeDirectory}/keys/certs/irc.pem";
 | 
			
		||||
          };
 | 
			
		||||
        }
 | 
			
		||||
      ];
 | 
			
		||||
      defaults = {
 | 
			
		||||
        # ignore join/leave messages
 | 
			
		||||
        ignore = true;
 | 
			
		||||
        nicks = ["toric"];
 | 
			
		||||
        realname = "Gabe Venberg";
 | 
			
		||||
        tls = true;
 | 
			
		||||
      };
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										362
									
								
								configs/home-manager/zellij/config.kdl
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										362
									
								
								configs/home-manager/zellij/config.kdl
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,362 @@
 | 
			
		|||
// If you'd like to override the default keybindings completely, be sure to change "keybinds" to "keybinds clear-defaults=true"
 | 
			
		||||
keybinds clear-defaults=true{
 | 
			
		||||
    normal {
 | 
			
		||||
        // uncomment this and adjust key if using copy_on_select=false
 | 
			
		||||
        // bind "Alt c" { Copy; }
 | 
			
		||||
    }
 | 
			
		||||
    locked {
 | 
			
		||||
        bind "Alt g" { SwitchToMode "Normal"; }
 | 
			
		||||
    }
 | 
			
		||||
    resize {
 | 
			
		||||
        bind "Alt r" { SwitchToMode "Normal"; }
 | 
			
		||||
        bind "h" "Left" { Resize "Increase Left"; }
 | 
			
		||||
        bind "j" "Down" { Resize "Increase Down"; }
 | 
			
		||||
        bind "k" "Up" { Resize "Increase Up"; }
 | 
			
		||||
        bind "l" "Right" { Resize "Increase Right"; }
 | 
			
		||||
        bind "H" { Resize "Decrease Left"; }
 | 
			
		||||
        bind "J" { Resize "Decrease Down"; }
 | 
			
		||||
        bind "K" { Resize "Decrease Up"; }
 | 
			
		||||
        bind "L" { Resize "Decrease Right"; }
 | 
			
		||||
        bind "=" "+" { Resize "Increase"; }
 | 
			
		||||
        bind "-" { Resize "Decrease"; }
 | 
			
		||||
    }
 | 
			
		||||
    pane {
 | 
			
		||||
        bind "Alt p" { SwitchToMode "Normal"; }
 | 
			
		||||
        bind "h" "Left" { MoveFocus "Left"; }
 | 
			
		||||
        bind "l" "Right" { MoveFocus "Right"; }
 | 
			
		||||
        bind "j" "Down" { MoveFocus "Down"; }
 | 
			
		||||
        bind "k" "Up" { MoveFocus "Up"; }
 | 
			
		||||
        bind "p" { SwitchFocus; }
 | 
			
		||||
        bind "n" { NewPane; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "d" { NewPane "Down"; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "r" { NewPane "Right"; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "x" { CloseFocus; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "f" { ToggleFocusFullscreen; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "z" { TogglePaneFrames; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "w" { ToggleFloatingPanes; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "e" { TogglePaneEmbedOrFloating; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "c" { SwitchToMode "RenamePane"; PaneNameInput 0;}
 | 
			
		||||
    }
 | 
			
		||||
    move {
 | 
			
		||||
        bind "Alt m" { SwitchToMode "Normal"; }
 | 
			
		||||
        bind "n" "Tab" { MovePane; }
 | 
			
		||||
        bind "p" { MovePaneBackwards; }
 | 
			
		||||
        bind "h" "Left" { MovePane "Left"; }
 | 
			
		||||
        bind "j" "Down" { MovePane "Down"; }
 | 
			
		||||
        bind "k" "Up" { MovePane "Up"; }
 | 
			
		||||
        bind "l" "Right" { MovePane "Right"; }
 | 
			
		||||
    }
 | 
			
		||||
    tab {
 | 
			
		||||
        bind "Alt t" { SwitchToMode "Normal"; }
 | 
			
		||||
        bind "r" { SwitchToMode "RenameTab"; TabNameInput 0; }
 | 
			
		||||
        bind "h" "Left" "Up" "k" { GoToPreviousTab; }
 | 
			
		||||
        bind "l" "Right" "Down" "j" { GoToNextTab; }
 | 
			
		||||
        bind "n" { NewTab; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "x" { CloseTab; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "s" { ToggleActiveSyncTab; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "b" { BreakPane; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "]" { BreakPaneRight; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "[" { BreakPaneLeft; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "1" { GoToTab 1; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "2" { GoToTab 2; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "3" { GoToTab 3; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "4" { GoToTab 4; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "5" { GoToTab 5; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "6" { GoToTab 6; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "7" { GoToTab 7; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "8" { GoToTab 8; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "9" { GoToTab 9; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "Tab" { ToggleTab; }
 | 
			
		||||
    }
 | 
			
		||||
    scroll {
 | 
			
		||||
        bind "Alt s" { SwitchToMode "Normal"; }
 | 
			
		||||
        bind "e" { EditScrollback; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "s" { SwitchToMode "EnterSearch"; SearchInput 0; }
 | 
			
		||||
        bind "Ctrl c" { ScrollToBottom; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "j" "Down" { ScrollDown; }
 | 
			
		||||
        bind "k" "Up" { ScrollUp; }
 | 
			
		||||
        bind "Ctrl f" "PageDown" "Right" "l" { PageScrollDown; }
 | 
			
		||||
        bind "Ctrl b" "PageUp" "Left" "h" { PageScrollUp; }
 | 
			
		||||
        bind "d" { HalfPageScrollDown; }
 | 
			
		||||
        bind "u" { HalfPageScrollUp; }
 | 
			
		||||
        // uncomment this and adjust key if using copy_on_select=false
 | 
			
		||||
        // bind "Alt c" { Copy; }
 | 
			
		||||
    }
 | 
			
		||||
    search {
 | 
			
		||||
        bind "Alt s" { SwitchToMode "Normal"; }
 | 
			
		||||
        bind "Ctrl c" { ScrollToBottom; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "j" "Down" { ScrollDown; }
 | 
			
		||||
        bind "k" "Up" { ScrollUp; }
 | 
			
		||||
        bind "Ctrl f" "PageDown" "Right" "l" { PageScrollDown; }
 | 
			
		||||
        bind "Ctrl b" "PageUp" "Left" "h" { PageScrollUp; }
 | 
			
		||||
        bind "d" { HalfPageScrollDown; }
 | 
			
		||||
        bind "u" { HalfPageScrollUp; }
 | 
			
		||||
        bind "n" { Search "down"; }
 | 
			
		||||
        bind "p" { Search "up"; }
 | 
			
		||||
        bind "c" { SearchToggleOption "CaseSensitivity"; }
 | 
			
		||||
        bind "w" { SearchToggleOption "Wrap"; }
 | 
			
		||||
        bind "o" { SearchToggleOption "WholeWord"; }
 | 
			
		||||
    }
 | 
			
		||||
    entersearch {
 | 
			
		||||
        bind "Ctrl c" "Esc" { SwitchToMode "Scroll"; }
 | 
			
		||||
        bind "Enter" { SwitchToMode "Search"; }
 | 
			
		||||
    }
 | 
			
		||||
    renametab {
 | 
			
		||||
        bind "Ctrl c" { SwitchToMode "Normal"; }
 | 
			
		||||
        bind "Esc" { UndoRenameTab; SwitchToMode "Tab"; }
 | 
			
		||||
    }
 | 
			
		||||
    renamepane {
 | 
			
		||||
        bind "Ctrl c" { SwitchToMode "Normal"; }
 | 
			
		||||
        bind "Esc" { UndoRenamePane; SwitchToMode "Pane"; }
 | 
			
		||||
    }
 | 
			
		||||
    session {
 | 
			
		||||
        bind "Alt o" { SwitchToMode "Normal"; }
 | 
			
		||||
        bind "Alt s" { SwitchToMode "Scroll"; }
 | 
			
		||||
        bind "d" { Detach; }
 | 
			
		||||
        bind "w" {
 | 
			
		||||
            LaunchOrFocusPlugin "zellij:session-manager" {
 | 
			
		||||
                floating true
 | 
			
		||||
                move_to_focused_tab true
 | 
			
		||||
            };
 | 
			
		||||
            SwitchToMode "Normal"
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
    tmux {
 | 
			
		||||
        bind "[" { SwitchToMode "Scroll"; }
 | 
			
		||||
        bind "Alt a" { Write 2; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "\"" { NewPane "Down"; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "%" { NewPane "Right"; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "z" { ToggleFocusFullscreen; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "c" { NewTab; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "," { SwitchToMode "RenameTab"; }
 | 
			
		||||
        bind "p" { GoToPreviousTab; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "n" { GoToNextTab; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "Left" { MoveFocus "Left"; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "Right" { MoveFocus "Right"; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "Down" { MoveFocus "Down"; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "Up" { MoveFocus "Up"; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "h" { MoveFocus "Left"; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "l" { MoveFocus "Right"; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "j" { MoveFocus "Down"; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "k" { MoveFocus "Up"; SwitchToMode "Normal"; }
 | 
			
		||||
        bind "o" { FocusNextPane; }
 | 
			
		||||
        bind "d" { Detach; }
 | 
			
		||||
        bind "Space" { NextSwapLayout; }
 | 
			
		||||
        bind "x" { CloseFocus; SwitchToMode "Normal"; }
 | 
			
		||||
    }
 | 
			
		||||
    shared_except "locked" {
 | 
			
		||||
        bind "Alt g" { SwitchToMode "Locked"; }
 | 
			
		||||
        bind "Alt q" { Quit; }
 | 
			
		||||
        bind "Alt n" { NewPane; }
 | 
			
		||||
        bind "Alt i" { MoveTab "Left"; }
 | 
			
		||||
        bind "Alt o" { MoveTab "Right"; }
 | 
			
		||||
        bind "Alt _" { NewPane "Down"; }
 | 
			
		||||
        bind "Alt |" { NewPane "Right"; }
 | 
			
		||||
        bind "Alt h" "Alt Left" { MoveFocusOrTab "Left"; }
 | 
			
		||||
        bind "Alt l" "Alt Right" { MoveFocusOrTab "Right"; }
 | 
			
		||||
        bind "Alt j" "Alt Down" { MoveFocus "Down"; }
 | 
			
		||||
        bind "Alt k" "Alt Up" { MoveFocus "Up"; }
 | 
			
		||||
        bind "Alt =" "Alt +" { Resize "Increase"; }
 | 
			
		||||
        bind "Alt -" { Resize "Decrease"; }
 | 
			
		||||
        bind "Alt [" { PreviousSwapLayout; }
 | 
			
		||||
        bind "Alt ]" { NextSwapLayout; }
 | 
			
		||||
    }
 | 
			
		||||
    shared_except "normal" "locked" {
 | 
			
		||||
        bind "Enter" "Esc" { SwitchToMode "Normal"; }
 | 
			
		||||
    }
 | 
			
		||||
    shared_except "pane" "locked" {
 | 
			
		||||
        bind "Alt p" { SwitchToMode "Pane"; }
 | 
			
		||||
    }
 | 
			
		||||
    shared_except "resize" "locked" {
 | 
			
		||||
        bind "Alt r" { SwitchToMode "Resize"; }
 | 
			
		||||
    }
 | 
			
		||||
    shared_except "scroll" "locked" {
 | 
			
		||||
        bind "Alt s" { SwitchToMode "Scroll"; }
 | 
			
		||||
    }
 | 
			
		||||
    shared_except "session" "locked" {
 | 
			
		||||
        bind "Alt o" { SwitchToMode "Session"; }
 | 
			
		||||
    }
 | 
			
		||||
    shared_except "tab" "locked" {
 | 
			
		||||
        bind "Alt t" { SwitchToMode "Tab"; }
 | 
			
		||||
    }
 | 
			
		||||
    shared_except "move" "locked" {
 | 
			
		||||
        bind "Alt m" { SwitchToMode "Move"; }
 | 
			
		||||
    }
 | 
			
		||||
    shared_except "tmux" "locked" {
 | 
			
		||||
        bind "Alt b" { SwitchToMode "Tmux"; }
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
plugins {
 | 
			
		||||
    tab-bar location="zellij:tab-bar"
 | 
			
		||||
    status-bar location="zellij:status-bar"
 | 
			
		||||
    strider location="zellij:strider"
 | 
			
		||||
    compact-bar location="zellij:compact-bar"
 | 
			
		||||
    session-manager location="zellij:session-manager"
 | 
			
		||||
    welcome-screen location="zellij:session-manager" {
 | 
			
		||||
        welcome_screen true
 | 
			
		||||
    }
 | 
			
		||||
    filepicker location="zellij:strider" {
 | 
			
		||||
        cwd "/"
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
// Choose what to do when zellij receives SIGTERM, SIGINT, SIGQUIT or SIGHUP
 | 
			
		||||
// eg. when terminal window with an active zellij session is closed
 | 
			
		||||
// Options:
 | 
			
		||||
//   - detach (Default)
 | 
			
		||||
//   - quit
 | 
			
		||||
//
 | 
			
		||||
// on_force_close "detach"
 | 
			
		||||
 | 
			
		||||
//  Send a request for a simplified ui (without arrow fonts) to plugins
 | 
			
		||||
//  Options:
 | 
			
		||||
//    - true
 | 
			
		||||
//    - false (Default)
 | 
			
		||||
//
 | 
			
		||||
// simplified_ui false
 | 
			
		||||
 | 
			
		||||
// Choose the path to the default shell that zellij will use for opening new panes
 | 
			
		||||
// Default: $SHELL
 | 
			
		||||
//
 | 
			
		||||
// default_shell "fish"
 | 
			
		||||
 | 
			
		||||
// Choose the path to override cwd that zellij will use for opening new panes
 | 
			
		||||
//
 | 
			
		||||
// default_cwd ""
 | 
			
		||||
 | 
			
		||||
// Toggle between having pane frames around the panes
 | 
			
		||||
// Options:
 | 
			
		||||
//   - true (default)
 | 
			
		||||
//   - false
 | 
			
		||||
//
 | 
			
		||||
// pane_frames true
 | 
			
		||||
 | 
			
		||||
// Toggle between having Zellij lay out panes according to a predefined set of layouts whenever possible
 | 
			
		||||
// Options:
 | 
			
		||||
//   - true (default)
 | 
			
		||||
//   - false
 | 
			
		||||
//
 | 
			
		||||
// auto_layout true
 | 
			
		||||
 | 
			
		||||
// Whether sessions should be serialized to the cache folder (including their tabs/panes, cwds and running commands) so that they can later be resurrected
 | 
			
		||||
// Options:
 | 
			
		||||
//   - true (default)
 | 
			
		||||
//   - false
 | 
			
		||||
//
 | 
			
		||||
// session_serialization false
 | 
			
		||||
 | 
			
		||||
// Whether pane viewports are serialized along with the session, default is false
 | 
			
		||||
// Options:
 | 
			
		||||
//   - true
 | 
			
		||||
//   - false (default)
 | 
			
		||||
// serialize_pane_viewport true
 | 
			
		||||
 | 
			
		||||
// Scrollback lines to serialize along with the pane viewport when serializing sessions, 0
 | 
			
		||||
// defaults to the scrollback size. If this number is higher than the scrollback size, it will
 | 
			
		||||
// also default to the scrollback size. This does nothing if `serialize_pane_viewport` is not true.
 | 
			
		||||
//
 | 
			
		||||
// scrollback_lines_to_serialize 10000
 | 
			
		||||
 | 
			
		||||
// Define color themes for Zellij
 | 
			
		||||
// For more examples, see: https://github.com/zellij-org/zellij/tree/main/example/themes
 | 
			
		||||
// Once these themes are defined, one of them should to be selected in the "theme" section of this file
 | 
			
		||||
//
 | 
			
		||||
themes {
 | 
			
		||||
    // example of how to set a theme in HEX format
 | 
			
		||||
 	gruvbox-dark {
 | 
			
		||||
 		fg "#D5C4A1"
 | 
			
		||||
 		bg "#282828"
 | 
			
		||||
 		black "#3C3836"
 | 
			
		||||
 		red "#CC241D"
 | 
			
		||||
 		green "#98971A"
 | 
			
		||||
 		yellow "#D79921"
 | 
			
		||||
 		blue "#3C8588"
 | 
			
		||||
 		magenta "#B16286"
 | 
			
		||||
 		cyan "#689D6A"
 | 
			
		||||
 		white "#FBF1C7"
 | 
			
		||||
 		orange "#D65D0E"
 | 
			
		||||
 	}
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
// Choose the theme that is specified in the themes section.
 | 
			
		||||
// Default: default
 | 
			
		||||
//
 | 
			
		||||
theme "gruvbox-dark"
 | 
			
		||||
 | 
			
		||||
// The name of the default layout to load on startup
 | 
			
		||||
// Default: "default"
 | 
			
		||||
//
 | 
			
		||||
// default_layout "compact"
 | 
			
		||||
 | 
			
		||||
// Choose the mode that zellij uses when starting up.
 | 
			
		||||
// Default: normal
 | 
			
		||||
//
 | 
			
		||||
// default_mode "locked"
 | 
			
		||||
 | 
			
		||||
// Toggle enabling the mouse mode.
 | 
			
		||||
// On certain configurations, or terminals this could
 | 
			
		||||
// potentially interfere with copying text.
 | 
			
		||||
// Options:
 | 
			
		||||
//   - true (default)
 | 
			
		||||
//   - false
 | 
			
		||||
//
 | 
			
		||||
// mouse_mode false
 | 
			
		||||
 | 
			
		||||
// Configure the scroll back buffer size
 | 
			
		||||
// This is the number of lines zellij stores for each pane in the scroll back
 | 
			
		||||
// buffer. Excess number of lines are discarded in a FIFO fashion.
 | 
			
		||||
// Valid values: positive integers
 | 
			
		||||
// Default value: 10000
 | 
			
		||||
//
 | 
			
		||||
// scroll_buffer_size 10000
 | 
			
		||||
 | 
			
		||||
// Provide a command to execute when copying text. The text will be piped to
 | 
			
		||||
// the stdin of the program to perform the copy. This can be used with
 | 
			
		||||
// terminal emulators which do not support the OSC 52 ANSI control sequence
 | 
			
		||||
// that will be used by default if this option is not set.
 | 
			
		||||
// Examples:
 | 
			
		||||
//
 | 
			
		||||
// copy_command "xclip -selection clipboard" // x11
 | 
			
		||||
// copy_command "wl-copy"                    // wayland
 | 
			
		||||
// copy_command "pbcopy"                     // osx
 | 
			
		||||
 | 
			
		||||
// Choose the destination for copied text
 | 
			
		||||
// Allows using the primary selection buffer (on x11/wayland) instead of the system clipboard.
 | 
			
		||||
// Does not apply when using copy_command.
 | 
			
		||||
// Options:
 | 
			
		||||
//   - system (default)
 | 
			
		||||
//   - primary
 | 
			
		||||
//
 | 
			
		||||
// copy_clipboard "primary"
 | 
			
		||||
 | 
			
		||||
// Enable or disable automatic copy (and clear) of selection when releasing mouse
 | 
			
		||||
// Default: true
 | 
			
		||||
//
 | 
			
		||||
// copy_on_select false
 | 
			
		||||
 | 
			
		||||
// Path to the default editor to use to edit pane scrollbuffer
 | 
			
		||||
// Default: $EDITOR or $VISUAL
 | 
			
		||||
//
 | 
			
		||||
// scrollback_editor "/usr/bin/vim"
 | 
			
		||||
 | 
			
		||||
// When attaching to an existing session with other users,
 | 
			
		||||
// should the session be mirrored (true)
 | 
			
		||||
// or should each user have their own cursor (false)
 | 
			
		||||
// Default: false
 | 
			
		||||
//
 | 
			
		||||
// mirror_session true
 | 
			
		||||
 | 
			
		||||
// The folder in which Zellij will look for layouts
 | 
			
		||||
//
 | 
			
		||||
// layout_dir "/path/to/my/layout_dir"
 | 
			
		||||
 | 
			
		||||
// The folder in which Zellij will look for themes
 | 
			
		||||
//
 | 
			
		||||
// theme_dir "/path/to/my/theme_dir"
 | 
			
		||||
 | 
			
		||||
// Enable or disable the rendering of styled and colored underlines (undercurl).
 | 
			
		||||
// May need to be disabled for certain unsupported terminals
 | 
			
		||||
// Default: true
 | 
			
		||||
//
 | 
			
		||||
// styled_underlines false
 | 
			
		||||
							
								
								
									
										11
									
								
								configs/home-manager/zellij/default.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										11
									
								
								configs/home-manager/zellij/default.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,11 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  lib,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  programs.zellij.enable = true;
 | 
			
		||||
  home.file = {
 | 
			
		||||
    ".config/zellij/config.kdl".source = ./config.kdl;
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										107
									
								
								configs/home-manager/zsh.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										107
									
								
								configs/home-manager/zsh.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,107 @@
 | 
			
		|||
{
 | 
			
		||||
  config,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  lib,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  programs = {
 | 
			
		||||
    starship.enableZshIntegration = true;
 | 
			
		||||
    fzf.enableZshIntegration = true;
 | 
			
		||||
    zoxide.enableZshIntegration = true;
 | 
			
		||||
    yazi.enableZshIntegration = true;
 | 
			
		||||
    eza.enableZshIntegration = true;
 | 
			
		||||
    direnv.enableZshIntegration = true;
 | 
			
		||||
    kitty.shellIntegration.enableZshIntegration = true;
 | 
			
		||||
    carapace.enableZshIntegration = false;
 | 
			
		||||
    zsh = {
 | 
			
		||||
      enable = true;
 | 
			
		||||
      enableCompletion = true;
 | 
			
		||||
      initExtra = lib.mkMerge [
 | 
			
		||||
        ''
 | 
			
		||||
          #have the menu highlight while we cycle through options
 | 
			
		||||
          zstyle ':completion:*' menu select
 | 
			
		||||
          #case insensitive completion
 | 
			
		||||
          zstyle ':completion:*' matcher-list 'm:{a-z}={A-Z}'
 | 
			
		||||
          #allow completion from midword
 | 
			
		||||
          setopt COMPLETE_IN_WORD
 | 
			
		||||
          #move cursor to end of word after completing
 | 
			
		||||
          setopt ALWAYS_TO_END
 | 
			
		||||
          #complete aliases as well
 | 
			
		||||
          setopt COMPLETE_ALIASES
 | 
			
		||||
          #select first item when you press tab the first time.
 | 
			
		||||
          setopt MENU_COMPLETE
 | 
			
		||||
          #case insensitive globbing
 | 
			
		||||
          setopt NO_CASE_GLOB
 | 
			
		||||
          #sort globs that expand to numbers by number rather than alphabeticly
 | 
			
		||||
          setopt NUMERIC_GLOB_SORT
 | 
			
		||||
          #allows for some neat globbing.
 | 
			
		||||
          setopt EXTENDED_GLOB
 | 
			
		||||
          #allow backspacing beyond the point you entered insert mode:
 | 
			
		||||
          bindkey -v '^?' backward-delete-char
 | 
			
		||||
          bindkey "^W" backward-kill-word
 | 
			
		||||
 | 
			
		||||
          #cheat.sh is a wonderful tool, the less typing needed the better.
 | 
			
		||||
          cheat(){
 | 
			
		||||
            for i in $*; do;
 | 
			
		||||
            curl cheat.sh/$i
 | 
			
		||||
            done
 | 
			
		||||
          }
 | 
			
		||||
        ''
 | 
			
		||||
        (lib.mkIf (!config.programs.starship.enable) ''
 | 
			
		||||
          autoload -U promptinit
 | 
			
		||||
          promptinit
 | 
			
		||||
          autoload -U colors
 | 
			
		||||
          colors
 | 
			
		||||
 | 
			
		||||
          #stuff to show git things.
 | 
			
		||||
            autoload -Uz vcs_info
 | 
			
		||||
            setopt prompt_subst
 | 
			
		||||
            precmd_vcs() {vcs_info}
 | 
			
		||||
            #when not in a repo, show full path to current directory. when in one, show path from base direcory of the repo.
 | 
			
		||||
            zstyle ':vcs_info:*' nvcsformats '%~'
 | 
			
		||||
            zstyle ':vcs_info:*' formats '%r/%S %F{green}[%b]%f'
 | 
			
		||||
            zstyle ':vcs_info:*' actionformats '%r/%S %F{green}[%b] %F{red}<%a>%f'
 | 
			
		||||
 | 
			
		||||
          #the precmd function, called just before printing the prompt.
 | 
			
		||||
          function precmd() {
 | 
			
		||||
            precmd_vcs
 | 
			
		||||
          }
 | 
			
		||||
 | 
			
		||||
          #Make the right prompt blank, just to be sure.
 | 
			
		||||
          RPROMPT=""
 | 
			
		||||
 | 
			
		||||
          #on the top line, show a whole bunch of info. botton line should be as minimal as possilbe (just a single char to  input next to...)
 | 
			
		||||
          PROMPT=$'%F{cyan}[%n@%m]%f%F{red}├────┤%f$${vcs_info_msg_0_} %F{white}[%D %T]%f\n»'
 | 
			
		||||
        '')
 | 
			
		||||
      ];
 | 
			
		||||
      autocd = true;
 | 
			
		||||
      autosuggestion.enable = true;
 | 
			
		||||
      defaultKeymap = "viins";
 | 
			
		||||
      history = {
 | 
			
		||||
        ignoreAllDups = true;
 | 
			
		||||
        extended = true;
 | 
			
		||||
      };
 | 
			
		||||
      shellAliases = {
 | 
			
		||||
        ll = "ls -lh";
 | 
			
		||||
        la = "ls -lha";
 | 
			
		||||
        please = "sudo $(fc -ln -1)";
 | 
			
		||||
        pyactivate = "source ./.venv/bin/activate";
 | 
			
		||||
      };
 | 
			
		||||
      syntaxHighlighting = {
 | 
			
		||||
        enable = true;
 | 
			
		||||
        highlighters = [
 | 
			
		||||
          "main"
 | 
			
		||||
          "brackets"
 | 
			
		||||
          "pattern"
 | 
			
		||||
          "regexp"
 | 
			
		||||
          "root"
 | 
			
		||||
          "line"
 | 
			
		||||
        ];
 | 
			
		||||
      };
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
  services.gpg-agent.enableZshIntegration = true;
 | 
			
		||||
  home.packages = with pkgs; [
 | 
			
		||||
    curl
 | 
			
		||||
  ];
 | 
			
		||||
}
 | 
			
		||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue