1
0
Prechádzať zdrojové kódy

Merge pull request #3 from tstachl/issues/001-make-it-easy

#1 make it easy
Zander Hawke 10 mesiacov pred
rodič
commit
b663ffc053
86 zmenil súbory, kde vykonal 1143 pridanie a 2488 odobranie
  1. 11 0
      .envrc
  2. 2 1
      .gitignore
  3. 33 0
      devenv.nix
  4. 84 72
      flake.lock
  5. 44 55
      flake.nix
  6. 0 14
      home/features/cli/aider-chat.nix
  7. 0 4
      home/features/cli/bash.nix
  8. 1 43
      home/features/cli/bat.nix
  9. 8 10
      home/features/cli/default.nix
  10. 0 3
      home/features/cli/direnv.nix
  11. 9 14
      home/features/cli/fish.nix
  12. 0 22
      home/features/cli/fzf.nix
  13. 18 100
      home/features/cli/git.nix
  14. 0 3
      home/features/cli/github.nix
  15. 4 5
      home/features/cli/gnupg.nix
  16. 0 4
      home/features/cli/nostr.nix
  17. 0 8
      home/features/cli/nushell.nix
  18. 0 10
      home/features/cli/pass.nix
  19. 0 24
      home/features/cli/shell-aliases.nix
  20. 6 16
      home/features/cli/ssh.nix
  21. 28 37
      home/features/cli/starship.nix
  22. 24 36
      home/features/cli/tmux.nix
  23. 0 4
      home/features/cli/yazi.nix
  24. 0 6
      home/features/cli/zoxide.nix
  25. 0 6
      home/features/cli/zsh.nix
  26. 9 8
      home/features/core.nix
  27. 7 105
      home/features/desktop/aerospace.nix
  28. 0 185
      home/features/desktop/alacritty.nix
  29. 3 2
      home/features/desktop/default.nix
  30. 1 2
      home/features/desktop/fonts.nix
  31. 23 69
      home/features/desktop/ghostty.nix
  32. 0 440
      home/features/desktop/logseq.nix
  33. 0 3
      home/features/desktop/syncthing.nix
  34. 5 5
      home/features/desktop/yubikey.nix
  35. 163 4
      home/features/desktop/zen-browser.nix
  36. 31 0
      home/features/nvim/copilot.nix
  37. 109 41
      home/features/nvim/default.nix
  38. 0 76
      home/features/nvim/keymaps.nix
  39. 151 150
      home/features/nvim/lsp.nix
  40. 71 0
      home/features/nvim/mini.nix
  41. 0 83
      home/features/nvim/options.nix
  42. 0 26
      home/features/nvim/plugins.nix
  43. 0 13
      home/features/nvim/plugins/avante.nix
  44. 0 44
      home/features/nvim/plugins/cmp.nix
  45. 0 3
      home/features/nvim/plugins/comment.nix
  46. 0 41
      home/features/nvim/plugins/conform.nix
  47. 0 29
      home/features/nvim/plugins/copilot.nix
  48. 0 32
      home/features/nvim/plugins/elixir-tools.nix
  49. 0 3
      home/features/nvim/plugins/fidget.nix
  50. 0 22
      home/features/nvim/plugins/gitsigns.nix
  51. 0 3
      home/features/nvim/plugins/indent-blankline.nix
  52. 0 13
      home/features/nvim/plugins/lint.nix
  53. 0 25
      home/features/nvim/plugins/mdx.nix
  54. 0 61
      home/features/nvim/plugins/mini.nix
  55. 0 14
      home/features/nvim/plugins/oil.nix
  56. 0 3
      home/features/nvim/plugins/sleuth.nix
  57. 0 58
      home/features/nvim/plugins/snacks.nix
  58. 0 117
      home/features/nvim/plugins/telescope.nix
  59. 0 3
      home/features/nvim/plugins/tmux.nix
  60. 0 4
      home/features/nvim/plugins/todo-comments.nix
  61. 0 3
      home/features/nvim/plugins/web-devicons.nix
  62. 0 51
      home/features/nvim/plugins/which-key.nix
  63. 0 18
      home/features/nvim/plugins/zenmode.nix
  64. 69 0
      home/features/nvim/telescope.nix
  65. 3 6
      home/features/nvim/treesitter.nix
  66. 22 0
      home/features/nvim/which-key.nix
  67. 4 2
      hosts/common/default.nix
  68. 7 5
      hosts/common/home-manager.nix
  69. 6 8
      hosts/common/nix.nix
  70. 15 6
      hosts/meili/default.nix
  71. 1 3
      hosts/meili/software.nix
  72. 1 2
      hosts/modgud/default.nix
  73. 4 2
      hosts/modgud/disk.nix
  74. 4 2
      hosts/modgud/hardware.nix
  75. 42 25
      lib/default.nix
  76. 5 12
      modules/darwin/networking/remote-login.nix
  77. 40 45
      modules/darwin/security/pam-reattach.nix
  78. 5 6
      modules/darwin/system/rosetta.nix
  79. 6 8
      modules/global/nix-config.nix
  80. 1 2
      modules/home-manager/default.nix
  81. 8 3
      overlays/default.nix
  82. 33 0
      packages/aerospace-tmux-focus.nix
  83. 3 7
      packages/default.nix
  84. 0 86
      packages/more-tmux-plugins.nix
  85. 4 2
      packages/photo-cli.nix
  86. 15 0
      packages/tmux-select-pane-no-wrap.nix

+ 11 - 0
.envrc

@@ -0,0 +1,11 @@
+if ! has nix_direnv_version || ! nix_direnv_version 2.2.1; then
+  source_url "https://raw.githubusercontent.com/nix-community/nix-direnv/2.2.1/direnvrc" "sha256-zelF0vLbEl5uaqrfIzbgNzJWGmLzCmYAkInj/LNxvKs="
+fi
+
+watch_file flake.nix
+watch_file flake.lock
+watch_file devenv.nix
+if ! use flake . --no-pure-eval
+then
+  echo "devenv could not be built. The devenv environment was not loaded. Make the necessary changes to devenv.nix and hit enter to try again." >&2
+fi

+ 2 - 1
.gitignore

@@ -4,4 +4,5 @@ result*
 *.qcow2
 .DS_Store
 cert*
-key*
+key*
+/.pre-commit-config.yaml

+ 33 - 0
devenv.nix

@@ -0,0 +1,33 @@
+{ pkgs, lib, ... }:
+{
+  git-hooks.hooks = {
+    deadnix.enable = true;
+    nixpkgs-fmt.enable = true;
+  };
+
+  scripts = {
+    update.exec = "nix flake update";
+
+    hmb.exec = ''
+      ${lib.getExe pkgs.home-manager} build --flake .#$(whoami)@$(hostname);
+    '';
+    hms.exec = ''
+      ${lib.getExe pkgs.home-manager} switch --flake .#$(whoami)@$(hostname);
+      zen --ProfileManager
+    '';
+
+    nrb.exec = ''
+      ${lib.getExe pkgs.nixos-rebuild} build --flake .#$(hostname);
+    '';
+    nrs.exec = ''
+      ${lib.getExe pkgs.nixos-rebuild} switch --flake .#$(hostname);
+    '';
+
+    drb.exec = ''
+      sudo darwin-rebuild build --flake .#$(hostname);
+    '';
+    drs.exec = ''
+      sudo darwin-rebuild switch --flake .#$(hostname);
+    '';
+  };
+}

+ 84 - 72
flake.lock

@@ -64,11 +64,11 @@
         ]
       },
       "locked": {
-        "lastModified": 1751727024,
-        "narHash": "sha256-0+3JCO+22Ud2395GeEnp+WZedC3f2B3KspH5t+1AUX4=",
+        "lastModified": 1753667201,
+        "narHash": "sha256-TwYZceH/tC83UCPwMWLk8v1AGHqkTuh1fi2c44UBMcg=",
         "owner": "cachix",
         "repo": "devenv",
-        "rev": "e33639c0535a8f18db417fd9fb36f180e8a7d27e",
+        "rev": "4d584d7686a50387f975879788043e55af9f0ad4",
         "type": "github"
       },
       "original": {
@@ -77,26 +77,6 @@
         "type": "github"
       }
     },
-    "disko": {
-      "inputs": {
-        "nixpkgs": [
-          "nixpkgs"
-        ]
-      },
-      "locked": {
-        "lastModified": 1751607816,
-        "narHash": "sha256-5PtrwjqCIJ4DKQhzYdm8RFePBuwb+yTzjV52wWoGSt4=",
-        "owner": "nix-community",
-        "repo": "disko",
-        "rev": "da6109c917b48abc1f76dd5c9bf3901c8c80f662",
-        "type": "github"
-      },
-      "original": {
-        "owner": "nix-community",
-        "repo": "disko",
-        "type": "github"
-      }
-    },
     "flake-compat": {
       "flake": false,
       "locked": {
@@ -143,11 +123,11 @@
         ]
       },
       "locked": {
-        "lastModified": 1749398372,
-        "narHash": "sha256-tYBdgS56eXYaWVW3fsnPQ/nFlgWi/Z2Ymhyu21zVM98=",
+        "lastModified": 1753121425,
+        "narHash": "sha256-TVcTNvOeWWk1DXljFxVRp+E0tzG1LhrVjOGGoMHuXio=",
         "owner": "hercules-ci",
         "repo": "flake-parts",
-        "rev": "9305fe4e5c2a6fcf5ba6a3ff155720fbe4076569",
+        "rev": "644e0fc48951a860279da645ba77fe4a6e814c5e",
         "type": "github"
       },
       "original": {
@@ -187,10 +167,11 @@
         ]
       },
       "locked": {
-        "lastModified": 1749636823,
+        "lastModified": 1750779888,
+        "narHash": "sha256-wibppH3g/E2lxU43ZQHC5yA/7kIKLGxVEnsnVK1BtRg=",
         "owner": "cachix",
         "repo": "git-hooks.nix",
-        "rev": "623c56286de5a3193aa38891a6991b28f9bab056",
+        "rev": "16ec914f6fb6f599ce988427d9d94efddf25fe6d",
         "type": "github"
       },
       "original": {
@@ -209,6 +190,7 @@
       },
       "locked": {
         "lastModified": 1709087332,
+        "narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=",
         "owner": "hercules-ci",
         "repo": "gitignore.nix",
         "rev": "637db329424fd7e46cf4185293b9cc8c88c95394",
@@ -227,11 +209,11 @@
         ]
       },
       "locked": {
-        "lastModified": 1751760902,
-        "narHash": "sha256-qBGNn7T/zOgUDQTo/RM/D2oxMkB2x36j3ajvpVanEVs=",
+        "lastModified": 1753675338,
+        "narHash": "sha256-KDS9sr7dddH97lUXa7oxfRqphBlCA6JxZO4m/Z4W06I=",
         "owner": "nix-community",
         "repo": "home-manager",
-        "rev": "8b0180dde1d6f4cf632e046309e8f963924dfbd0",
+        "rev": "e4b032ba5113664f0b8b23d956e59ce8e0bc349d",
         "type": "github"
       },
       "original": {
@@ -241,6 +223,27 @@
         "type": "github"
       }
     },
+    "home-manager_2": {
+      "inputs": {
+        "nixpkgs": [
+          "zen-browser",
+          "nixpkgs"
+        ]
+      },
+      "locked": {
+        "lastModified": 1752603129,
+        "narHash": "sha256-S+wmHhwNQ5Ru689L2Gu8n1OD6s9eU9n9mD827JNR+kw=",
+        "owner": "nix-community",
+        "repo": "home-manager",
+        "rev": "e8c19a3cec2814c754f031ab3ae7316b64da085b",
+        "type": "github"
+      },
+      "original": {
+        "owner": "nix-community",
+        "repo": "home-manager",
+        "type": "github"
+      }
+    },
     "ixx": {
       "inputs": {
         "flake-utils": [
@@ -280,7 +283,10 @@
           "devenv",
           "git-hooks"
         ],
-        "nixpkgs": "nixpkgs",
+        "nixpkgs": [
+          "devenv",
+          "nixpkgs"
+        ],
         "nixpkgs-23-11": [
           "devenv"
         ],
@@ -289,11 +295,11 @@
         ]
       },
       "locked": {
-        "lastModified": 1750955511,
-        "narHash": "sha256-IDB/oh/P63ZTdhgSkey2LZHzeNhCdoKk+4j7AaPe1SE=",
+        "lastModified": 1752773918,
+        "narHash": "sha256-dOi/M6yNeuJlj88exI+7k154z+hAhFcuB8tZktiW7rg=",
         "owner": "cachix",
         "repo": "nix",
-        "rev": "afa41b08df4f67b8d77a8034b037ac28c71c77df",
+        "rev": "031c3cf42d2e9391eee373507d8c12e0f9606779",
         "type": "github"
       },
       "original": {
@@ -305,27 +311,27 @@
     },
     "nixpkgs": {
       "locked": {
-        "lastModified": 1747179050,
-        "narHash": "sha256-qhFMmDkeJX9KJwr5H32f1r7Prs7XbQWtO0h3V0a0rFY=",
-        "owner": "NixOS",
+        "lastModified": 1753345091,
+        "narHash": "sha256-CdX2Rtvp5I8HGu9swBmYuq+ILwRxpXdJwlpg8jvN4tU=",
+        "owner": "nixos",
         "repo": "nixpkgs",
-        "rev": "adaa24fbf46737f3f1b5497bf64bae750f82942e",
+        "rev": "3ff0e34b1383648053bba8ed03f201d3466f90c9",
         "type": "github"
       },
       "original": {
-        "owner": "NixOS",
-        "ref": "nixos-unstable",
+        "owner": "nixos",
+        "ref": "nixos-25.05",
         "repo": "nixpkgs",
         "type": "github"
       }
     },
     "nixpkgs-darwin": {
       "locked": {
-        "lastModified": 1751582995,
-        "narHash": "sha256-u7ubvtxdTnFPpV27AHpgoKn7qHuE7sgWgza/1oj5nzA=",
+        "lastModified": 1753634013,
+        "narHash": "sha256-DKW2YBGvrFxmbcGcjzq75YJJYCYUSOVq3vdXonLrM3E=",
         "owner": "nixos",
         "repo": "nixpkgs",
-        "rev": "7a732ed41ca0dd64b4b71b563ab9805a80a7d693",
+        "rev": "613ea8c1cfcf8fd760b9557426889e4483d6496f",
         "type": "github"
       },
       "original": {
@@ -337,11 +343,11 @@
     },
     "nixpkgs-unstable": {
       "locked": {
-        "lastModified": 1751625545,
-        "narHash": "sha256-4E7wWftF1ExK5ZEDzj41+9mVgxtuRV3wWCId7QAYMAU=",
+        "lastModified": 1753432016,
+        "narHash": "sha256-cnL5WWn/xkZoyH/03NNUS7QgW5vI7D1i74g48qplCvg=",
         "owner": "nixos",
         "repo": "nixpkgs",
-        "rev": "c860cf0b3a0829f0f6cf344ca8de83a2bbfab428",
+        "rev": "6027c30c8e9810896b92429f0092f624f7b1aace",
         "type": "github"
       },
       "original": {
@@ -351,22 +357,6 @@
         "type": "github"
       }
     },
-    "nixpkgs_2": {
-      "locked": {
-        "lastModified": 1751582995,
-        "narHash": "sha256-u7ubvtxdTnFPpV27AHpgoKn7qHuE7sgWgza/1oj5nzA=",
-        "owner": "nixos",
-        "repo": "nixpkgs",
-        "rev": "7a732ed41ca0dd64b4b71b563ab9805a80a7d693",
-        "type": "github"
-      },
-      "original": {
-        "owner": "nixos",
-        "ref": "nixos-25.05",
-        "repo": "nixpkgs",
-        "type": "github"
-      }
-    },
     "nixvim": {
       "inputs": {
         "flake-parts": "flake-parts_2",
@@ -377,11 +367,11 @@
         "systems": "systems_2"
       },
       "locked": {
-        "lastModified": 1751479430,
-        "narHash": "sha256-ub1Pj+oSrt2bE1tzTRYEwzCFewsc9F7X7RIJooM94MU=",
+        "lastModified": 1753534875,
+        "narHash": "sha256-U8eKkKR+c70Sj+XuhbCzRAWJBfRLEF7Qh7gKk/7f93M=",
         "owner": "nix-community",
         "repo": "nixvim",
-        "rev": "13cc4d84572c5f5d469a3a3454fa2028f78a3137",
+        "rev": "f25f269dddf2e464f0d4a79bb42b6bfbab63b0df",
         "type": "github"
       },
       "original": {
@@ -401,11 +391,11 @@
         ]
       },
       "locked": {
-        "lastModified": 1749730855,
-        "narHash": "sha256-L3x2nSlFkXkM6tQPLJP3oCBMIsRifhIDPMQQdHO5xWo=",
+        "lastModified": 1753450833,
+        "narHash": "sha256-Pmpke0JtLRzgdlwDC5a+aiLVZ11JPUO5Bcqkj0nHE/k=",
         "owner": "NuschtOS",
         "repo": "search",
-        "rev": "8dfe5879dd009ff4742b668d9c699bc4b9761742",
+        "rev": "40987cc1a24feba378438d691f87c52819f7bd75",
         "type": "github"
       },
       "original": {
@@ -418,12 +408,12 @@
       "inputs": {
         "darwin": "darwin",
         "devenv": "devenv",
-        "disko": "disko",
         "home-manager": "home-manager",
-        "nixpkgs": "nixpkgs_2",
+        "nixpkgs": "nixpkgs",
         "nixpkgs-darwin": "nixpkgs-darwin",
         "nixpkgs-unstable": "nixpkgs-unstable",
-        "nixvim": "nixvim"
+        "nixvim": "nixvim",
+        "zen-browser": "zen-browser"
       }
     },
     "systems": {
@@ -455,6 +445,28 @@
         "repo": "default",
         "type": "github"
       }
+    },
+    "zen-browser": {
+      "inputs": {
+        "home-manager": "home-manager_2",
+        "nixpkgs": [
+          "nixpkgs-unstable"
+        ]
+      },
+      "locked": {
+        "lastModified": 1753674409,
+        "narHash": "sha256-jhBdIc802upDu3S/Nu0rgVlIJ39E8KWugQwm/a74MBY=",
+        "owner": "0xc000022070",
+        "repo": "zen-browser-flake",
+        "rev": "e1bf71a0eb5ff9fdcfe83f6e4676ce19dd87f468",
+        "type": "github"
+      },
+      "original": {
+        "owner": "0xc000022070",
+        "ref": "main",
+        "repo": "zen-browser-flake",
+        "type": "github"
+      }
     }
   },
   "root": "root",

+ 44 - 55
flake.nix

@@ -1,6 +1,4 @@
 {
-  description = "my nix configuration";
-
   inputs = {
     nixpkgs.url = "github:nixos/nixpkgs/nixos-25.05?shallow=true";
     nixpkgs-darwin.url = "github:nixos/nixpkgs/nixpkgs-25.05-darwin?shallow=true";
@@ -12,74 +10,65 @@
     devenv.url = "github:cachix/devenv?shallow=true";
     devenv.inputs.nixpkgs.follows = "nixpkgs-unstable";
 
-    disko.url = "github:nix-community/disko?shallow=true";
-    disko.inputs.nixpkgs.follows = "nixpkgs";
-
     home-manager.url = "github:nix-community/home-manager/master?shallow=true";
     home-manager.inputs.nixpkgs.follows = "nixpkgs";
 
     nixvim.url = "github:nix-community/nixvim/nixos-25.05?shallow=true";
     nixvim.inputs.nixpkgs.follows = "nixpkgs";
-  };
-
-  outputs =
-    {
-      self,
 
-      nixpkgs,
-      nixpkgs-darwin,
-      nixpkgs-unstable,
-
-      devenv,
-      disko,
-      home-manager,
-      nixvim,
+    zen-browser.url = "github:0xc000022070/zen-browser-flake/main?shallow=true";
+    zen-browser.inputs.nixpkgs.follows = "nixpkgs-unstable";
+  };
 
-      ...
-    }@inputs:
-    rec {
+  outputs = { self, ... } @ inputs: rec {
+    lib = import ./lib {
+      inherit inputs;
+      inherit (self) outputs;
+    };
 
-      lib = import ./lib {
-        inherit inputs;
-        inherit (self) outputs;
+    homeConfigurations = {
+      "thomas@meili" = lib.mkHome {
+        system = "aarch64-darwin";
+        modules = [ ./home/meili.nix ];
       };
 
-      homeConfigurations = {
-        "thomas@meili" = lib.mkHome {
-          system = "aarch64-darwin";
-          modules = [ ./home/meili.nix ];
-        };
-
-        "thomas@modgud" = lib.mkHome {
-          system = "x86_64-linux";
-          modules = [ ./home/modgud.nix ];
-        };
+      "thomas@modgud" = lib.mkHome {
+        system = "x86_64-linux";
+        modules = [ ./home/modgud.nix ];
       };
+    };
 
-      nixosConfigurations = {
-        modgud = lib.mkSystem {
-          system = "x86_64-linux";
-          modules = [ ./hosts/modgud ];
-        };
+    nixosConfigurations = {
+      # modgud = lib.mkSystem {
+      #   system = "x86_64-linux";
+      #   modules = [ ./hosts/modgud ];
+      # };
 
-        odin = lib.mkSystem {
-          system = "x86_64-linux";
-          modules = [ ./hosts/odin ];
-        };
-      };
+      # odin = lib.mkSystem {
+      #   system = "x86_64-linux";
+      #   modules = [ ./hosts/odin ];
+      # };
+    };
 
-      darwinConfigurations = {
-        meili = lib.mkDarwin {
-          system = "aarch64-darwin";
-          modules = [ ./hosts/meili ];
-        };
+    darwinConfigurations = {
+      meili = lib.mkDarwin {
+        system = "aarch64-darwin";
+        modules = [ ./hosts/meili ];
       };
+    };
 
-      modules = import ./modules;
-      overlays = import ./overlays { inherit inputs; };
-
-      packages = lib.eachSystemWithPkgs (import ./packages);
-      codecov-cli = inputs.nixpkgs-unstable.legacyPackages.aarch64-darwin.codecov-cli;
-      formatter = lib.eachSystem (system: nixpkgs.legacyPackages.${system}.nixfmt-rfc-style);
+    devShells = lib.mkDevenvShell {
+      default = import ./devenv.nix;
     };
+
+    modules = import ./modules;
+    overlays = import ./overlays { inherit inputs; };
+
+    packages =
+      lib.eachSystem (import ./packages)
+      // lib.eachSystem (system: {
+        devenv-up = self.devShells.${system}.default.config.procfileScript;
+        devenv-test = self.devShells.${system}.default.config.test;
+      });
+  };
 }

+ 0 - 14
home/features/cli/aider-chat.nix

@@ -1,14 +0,0 @@
-{ pkgs, ... }:
-{
-  home.packages = with pkgs; [
-    aider-chat
-  ];
-
-  home.sessionVariables = {
-    OPENROUTER_API_KEY = "";
-  };
-
-  # programs.fish.interactiveShellInit = ''
-  #   set OPENROUTER_API_KEY $(pass openrouter.ai/avante)
-  # '';
-}

+ 0 - 4
home/features/cli/bash.nix

@@ -1,4 +0,0 @@
-{
-  programs.bash.enable = true;
-  programs.bash.shellAliases = import ./shell-aliases.nix;
-}

+ 1 - 43
home/features/cli/bat.nix

@@ -1,52 +1,10 @@
 { pkgs, ... }:
-
-let
-  catppuccin-src = pkgs.fetchFromGitHub {
-    owner = "catppuccin";
-    repo = "bat";
-    rev = "699f60f";
-    sha256 = "sha256-6fWoCH90IGumAMc4buLRWL0N61op+AuMNN9CAR9/OdI=";
-  };
-in
-
 {
   programs.bat = {
     enable = true;
-    config = {
-      theme = "catppuccin-frappe";
-    };
+    config.theme = "kanagawa";
 
     themes = {
-      catppuccin-latte = {
-        src = catppuccin-src;
-        file = "/themes/Catppuccin Latte.tmTheme";
-      };
-
-      catppuccin-frappe = {
-        src = catppuccin-src;
-        file = "/themes/Catppuccin Frappe.tmTheme";
-      };
-
-      catppuccin-macchiato = {
-        src = catppuccin-src;
-        file = "/themes/Catppuccin Macchiato.tmTheme";
-      };
-
-      catppuccin-mocha = {
-        src = catppuccin-src;
-        file = "/themes/Catppuccin Mocha.tmTheme";
-      };
-
-      nord = {
-        src = pkgs.fetchFromGitHub {
-          owner = "crabique";
-          repo = "Nord-plist";
-          rev = "0d655b23d6b300e691676d9b90a68d92b267f7ec";
-          sha256 = "sha256-YUogcLO+W1hD0X/nsworGS1SHsOolp/g9N0rQJ/Q5wc=";
-        };
-        file = "/Nord.tmTheme";
-      };
-
       kanagawa = {
         src = pkgs.fetchFromGitHub {
           owner = "rebelot";

+ 8 - 10
home/features/cli/default.nix

@@ -1,21 +1,19 @@
+{ pkgs, ... }:
 {
   imports = [
-    ./aider-chat.nix
-    ./bash.nix
     ./bat.nix
-    ./direnv.nix
     ./fish.nix
-    ./fzf.nix
     ./git.nix
     ./gnupg.nix
-    ./nostr.nix
-    ./nushell.nix
-    ./pass.nix
     ./ssh.nix
     ./starship.nix
     ./tmux.nix
-    ./yazi.nix
-    ./zoxide.nix
-    ./zsh.nix
   ];
+
+  home.packages = [ pkgs.unstable.nak ];
+
+  programs.bash.enable = true;
+  programs.direnv.enable = true;
+  programs.zoxide.enable = true;
+  programs.zsh.enable = true;
 }

+ 0 - 3
home/features/cli/direnv.nix

@@ -1,3 +0,0 @@
-{
-  programs.direnv.enable = true;
-}

+ 9 - 14
home/features/cli/fish.nix

@@ -1,18 +1,13 @@
 { lib, pkgs, ... }:
 {
-  programs.fish = {
-    enable = true;
-    shellAliases = import ./shell-aliases.nix;
+  programs.fish.enable = true;
 
-    interactiveShellInit = lib.mkAfter ''
-      fish_config theme choose "Catppuccin Frappe"
-    '';
-  };
-
-  xdg.configFile."fish/themes/Catppuccin Frappe.theme".text = lib.strings.fileContents (pkgs.fetchFromGitHub {
-    owner = "catppuccin";
-    repo = "fish";
-    rev = "cc8e4d8";
-    sha256 = "sha256-udiU2TOh0lYL7K7ylbt+BGlSDgCjMpy75vQ98C1kFcc=";
-  } + "/themes/Catppuccin Frappe.theme");
+  xdg.configFile."fish/conf.d/kanagawa.fish".text =
+    lib.strings.fileContents (pkgs.fetchFromGitHub
+      {
+        owner = "rebelot";
+        repo = "kanagawa.nvim";
+        rev = "83e377c";
+        sha256 = "sha256-IBZFfQRNvIEIFiQF5Gm4LGTmRc2VCWy4Gx51RhtDNDM=";
+      } + "/extras/fish/kanagawa.fish");
 }

+ 0 - 22
home/features/cli/fzf.nix

@@ -1,22 +0,0 @@
-{ pkgs, ... }:
-{
-  home.packages = with pkgs; [ fd ];
-
-  programs.fzf = rec {
-    # TODO(@tstachl): figure out why this is happening in tmux
-    # fish: Unknown command: fzf_key_bindings
-    # source /nix/store/.../share/fzf/key-bindings.fish && fzf_key_bindings
-    enable = false;
-    changeDirWidgetCommand = defaultCommand;
-    changeDirWidgetOptions = [ "--type=d" ] ++ defaultOptions;
-    defaultCommand = "${pkgs.fd}/bin/fd";
-    defaultOptions = [
-      "--strip-cwd-prefix"
-      "--hidden"
-      "--exclude .git"
-    ];
-    fileWidgetCommand = defaultCommand;
-    fileWidgetOptions = [ "--type=f" ] ++ defaultOptions;
-    tmux.enableShellIntegration = true;
-  };
-}

+ 18 - 100
home/features/cli/git.nix

@@ -1,30 +1,26 @@
-{ pkgs, ... }:
-{
-  home.packages = [
-    pkgs.git
-    pkgs.git-crypt
-    pkgs.codeberg-cli
-  ];
+{ pkgs, ... }: {
 
-  programs.gh.enable = true;
+  home.packages = with pkgs; [ git-crypt ];
 
   programs.git = {
     enable = true;
     userName = "Thomas Stachl";
     userEmail = "[email protected]";
 
-    includes = [{
-      condition = "gitdir/i:~/workspace/aesir/**";
-      contents = {
-        core.sshCommand = "ssh -i ~/.ssh/id_aesirdev";
-        user = {
-          email = "[email protected]";
-          name = "Æsir Dev";
-          signingKey = "58145313C9636027";
+    includes = [
+      {
+        condition = "gitdir/i:~/workspace/aesir/**";
+        contents = {
+          core.sshCommand = "ssh -i ~/.ssh/id_aesirdev";
+          user = {
+            email = "[email protected]";
+            name = "Æsir Dev";
+            signingKey = "58145313C9636027";
+          };
+          commit.gpgSign = true;
         };
-        commit.gpgSign = true;
-      };
-    }];
+      }
+    ];
 
     signing = {
       key = "ED5EAAA8E895B23A";
@@ -32,74 +28,7 @@
       signer = "${pkgs.gnupg}/bin/gpg";
     };
 
-    aliases = {
-      b = "branch";
-      bc = "checkout -b";
-      bl = "branch -v";
-      bL = "branch -av";
-      bx = "branch -d";
-      bX = "branch -D";
-      bm = "branch -m";
-      bM = "branch -M";
-      bs = "show-branch";
-      bS = "show-branch -a";
-      co = "checkout";
-      co0 = "checkout HEAD --";
-      f = "fetch";
-      fm = "pull";
-      fo = "fetch origin";
-      m = "merge";
-      mom = "merge origin/master";
-      p = "push";
-      pa = "push --all";
-      pt = "push --tags";
-      r = "rebase";
-      ra = "rebase --abort";
-      rc = "rebase --continue";
-      ri = "rebase --interactive";
-      rs = "rebase --skip";
-      rom = "rebase origin/master";
-      c = "commit -v";
-      ca = "commit --all -v";
-      cm = "commit --message";
-      cam = "commit --all --message";
-      camend = "commit --amend --reuse-message HEAD";
-      cundo = "reset --soft 'HEAD^'";
-      cp = "cherry-pick";
-      d = "diff          # Diff working dir to index";
-      ds = "diff --staged # Diff index to HEAD";
-      dc = "diff --staged # Diff index to HEAD";
-      dh = "diff HEAD     # Diff working dir and index to HEAD";
-      hub = "browse";
-      hubd = "compare";
-      s = "status";
-      a = "add";
-      ia = "add";
-      ir = "reset";
-      l = "log --topo-order --pretty=format:'%C(yellow)%h %C(cyan)%cn %C(blue)%cr%C(reset) %s'";
-      ls = "log --topo-order --stat --pretty=format:'%C(bold)%C(yellow)Commit:%C(reset) %C(yellow)%H%C(red)%d%n%C(bold)%C(yellow)Author:%C(reset) %C(cyan)%an <%ae>%n%C(bold)%C(yellow)Date:%C(reset)   %C(blue)%ai (%ar)%C(reset)%n%+B'";
-      ld = "log --topo-order --stat --patch --full-diff --pretty=format:'%C(bold)%C(yellow)Commit:%C(reset) %C(yellow)%H%C(red)%d%n%C(bold)%C(yellow)Author:%C(reset) %C(cyan)%an <%ae>%n%C(bold)%C(yellow)Date:%C(reset)   %C(blue)%ai (%ar)%C(reset)%n%+B'";
-      lg = "log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit";
-      lga = "log --topo-order --all --graph --pretty=format:'%C(yellow)%h %C(cyan)%cn%C(reset) %s %C(red)%d%C(reset)%n'";
-      lm = "log --topo-order --pretty=format:'%s'";
-      lh = "shortlog --summary --numbered";
-      llf = "fsck --lost-found";
-      lg1 = "log --graph --abbrev-commit --decorate --date=relative --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(bold yellow)%d%C(reset)' --all";
-      lg2 = "log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n''          %C(white)%s%C(reset) %C(dim white)- %an%C(reset)' --all";
-      re = "remote";
-      rel = "remote --verbose";
-      rea = "remote add";
-      rex = "remote rm";
-      rem = "remote rename";
-    };
-
     extraConfig = {
-      core = {
-        editor = "vim";
-        pager = "less -FRSX";
-        whitespace = "fix,-indent-with-non-tab,trailing-space,cr-at-eol";
-      };
-
       color = {
         grep = "always";
         pager = "true";
@@ -132,17 +61,15 @@
         };
       };
 
-      diff.tool = "vimdiff";
-      difftool.prompt = "false";
-      merge.tool = "vimdiff";
-      push.default = "matching";
-      pull.rebase = "false";
       init.defaultBranch = "master";
 
       url = {
         "[email protected]:" = {
           insteadOf = "github:";
         };
+        "[email protected]:" = {
+          insteadOf = "codeberg:";
+        };
       };
 
       branch = {
@@ -154,12 +81,3 @@
     };
   };
 }
-
-# [filter "lfs"]
-# 	clean = git-lfs clean -- %f
-# 	smudge = git-lfs smudge -- %f
-# 	process = git-lfs filter-process
-# 	required = true
-
-# TODO: Proton Drive
-# ln -s ~/Library/CloudStorage/[email protected]/Photos ~/Photos

+ 0 - 3
home/features/cli/github.nix

@@ -1,3 +0,0 @@
-{
-  programs.gh.enable = true;
-}

+ 4 - 5
home/features/cli/gnupg.nix

@@ -1,8 +1,7 @@
-{
-  config,
-  lib,
-  pkgs,
-  ...
+{ config
+, lib
+, pkgs
+, ...
 }:
 let
   configHome = "${config.xdg.configHome}/gnupg";

+ 0 - 4
home/features/cli/nostr.nix

@@ -1,4 +0,0 @@
-{ pkgs, ... }:
-{
-  home.packages = [ pkgs.unstable.nak ];
-}

+ 0 - 8
home/features/cli/nushell.nix

@@ -1,8 +0,0 @@
-{ config, ... }:
-{
-  home.sessionVariables.SHELL = "${config.programs.nushell.package}/bin/nu";
-  programs.nushell = {
-    enable = true;
-    shellAliases = import ./shell-aliases.nix;
-  };
-}

+ 0 - 10
home/features/cli/pass.nix

@@ -1,10 +0,0 @@
-{ config, ... }:
-{
-  programs.password-store.enable = true;
-
-  programs.fish.shellInit = ''
-    set PASSWORD_STORE_DIR "${config.xdg.dataHome}/password-store";
-    set PASSWORD_STORE_KEY "7A53D4C6B481F7711588D34FDE749C31D060A160";
-    set PASSWORD_STORE_SIGNING_KEY "7A53D4C6B481F7711588D34FDE749C31D060A160";
-  '';
-}

+ 0 - 24
home/features/cli/shell-aliases.nix

@@ -1,24 +0,0 @@
-{
-  "..." = "cd ../..";
-  "...." = "cd ../../..";
-
-  la = "ls -la";
-
-  # Git stuff
-  g = "git";
-  gco = "git checkout ";
-  gcob = "git checkout -b ";
-  ghic = "gh issue create --body '' ";
-
-  # nix stuff
-  hmb = "nix run github:nix-community/home-manager -- build --flake .#(whoami)@(hostname)";
-  hms = "nix run github:nix-community/home-manager -- switch --flake .#(whoami)@(hostname)";
-
-  home-manager = "nix run github:nix-community/home-manager --";
-
-  drb = "nix run github:lnl7/nix-darwin -- build --flake .#(hostname)";
-  drs = "nix run github:lnl7/nix-darwin -- switch --flake .#(hostname)";
-
-  nrb = "nixos-rebuild build --flake .#(hostname)";
-  nrs = "nixos-rebuild switch --flake .#(hostname)";
-}

+ 6 - 16
home/features/cli/ssh.nix

@@ -1,4 +1,7 @@
-{ config, lib, ... }:
+{ config
+, lib
+, ...
+}:
 let
   configHome = "${config.xdg.configHome}/gnupg";
 in
@@ -17,23 +20,10 @@ in
     '';
 
     matchBlocks = {
-      modgud = {
-        hostname = "modgud.t5.st";
-        user = "thomas";
-        remoteForwards = [
-          {
-            host.address = "${configHome}/S.gpg-agent.extra";
-            bind.address = "/run/user/1000/gnupg/d.o6jzqfigwppq1eps4nhng6n5/S.gpg-agent";
-          }
-          {
-            host.address = "${configHome}/S.gpg-agent.ssh";
-            bind.address = "/run/user/1000/gnupg/d.o6jzqfigwppq1eps4nhng6n5/S.gpg-agent.ssh";
-          }
-        ];
-      };
-
       "github.com".user = "git";
+      "codeberg.org".user = "git";
       github.hostname = "github.com";
+      codeberg.hostname = "codeberg.org";
     };
   };
 }

+ 28 - 37
home/features/cli/starship.nix

@@ -2,48 +2,39 @@
   programs.starship = {
     enable = true;
     enableFishIntegration = true;
-    enableNushellIntegration = true;
     enableTransience = true;
 
     settings = {
-      shell = {
-        disabled = false;
-        fish_indicator = "🐟";
-        nu_indicator = "☘️";
-        bash_indicator = "🐻";
-        zsh_indicator = "🐚";
+      palettes.kanagawa = {
+        rosewater = "#DCD7BA";
+        flamingo = "#E6C384";
+        pink = "#957FB8";
+        mauve = "#938AA9";
+        red = "#C34043";
+        maroon = "#E82424";
+        peach = "#C0A36E";
+        yellow = "#E6C384";
+        green = "#76946A";
+        teal = "#6A9589";
+        sky = "#7AA89F";
+        sapphire = "#7FB4CA";
+        blue = "#7E9CD8";
+        lavender = "#72A7BC";
+        text = "#DCD7BA";
+        subtext1 = "#C8C093";
+        subtext0 = "#98BB6C";
+        overlay2 = "#727169";
+        overlay1 = "#727169";
+        overlay0 = "#727169";
+        surface2 = "#2D4F67";
+        surface1 = "#2D4F67";
+        surface0 = "#2D4F67";
+        base = "#1F1F28";
+        mantle = "#16161D";
+        crust = "#16161D";
       };
 
-      palettes.catppuccin_frappe = {
-        rosewater = "#f2d5cf";
-        flamingo = "#eebebe";
-        pink = "#f4b8e4";
-        mauve = "#ca9ee6";
-        red = "#e78284";
-        maroon = "#ea999c";
-        peach = "#ef9f76";
-        yellow = "#e5c890";
-        green = "#a6d189";
-        teal = "#81c8be";
-        sky = "#99d1db";
-        sapphire = "#85c1dc";
-        blue = "#8caaee";
-        lavender = "#babbf1";
-        text = "#c6d0f5";
-        subtext1 = "#b5bfe2";
-        subtext0 = "#a5adce";
-        overlay2 = "#949cbb";
-        overlay1 = "#838ba7";
-        overlay0 = "#737994";
-        surface2 = "#626880";
-        surface1 = "#51576d";
-        surface0 = "#414559";
-        base = "#303446";
-        mantle = "#292c3c";
-        crust = "#232634";
-      };
-
-      palette = "catppuccin_frappe";
+      palette = "kanagawa";
     };
   };
 }

+ 24 - 36
home/features/cli/tmux.nix

@@ -1,14 +1,10 @@
-{ pkgs, config, ... }:
-{
-  # - WARNING Neither Tc nor RGB capability set. True colors are disabled. |'termguicolors'| won't work properly.
-  #   - ADVICE:
-  #     - Put this in your ~/.tmux.conf and replace XXX by your $TERM outside of tmux:
-  #       set-option -sa terminal-features ',XXX:RGB'
-  #     - For older tmux versions use this instead:
-  #       set-option -ga terminal-overrides ',XXX:Tc'
-
+{ pkgs
+, config
+, lib
+, ...
+}: {
   programs.tmux = {
-    sensibleOnTop = false;
+    sensibleOnTop = true;
 
     baseIndex = 1;
     clock24 = true;
@@ -17,20 +13,13 @@
     keyMode = "vi";
     mouse = true;
     prefix = "C-a";
-    # shell = "${pkgs.fish}/bin/fish";
-    shell = "${pkgs.lib.meta.getExe config.programs.fish.package}";
+    shell = "${lib.getExe config.programs.fish.package}";
     terminal = "tmux-256color";
 
     plugins = with pkgs.tmuxPlugins; [
-      pkgs.more-tmux-plugins.tmux-select-pane-no-wrap
-      {
-        plugin = catppuccin;
-        extraConfig = ''
-          set -g @catppuccin_flavor 'frappe' # latte, frappe, macchiato or mocha
-        '';
-      }
-      vim-tmux-focus-events
+      tmux-select-pane-no-wrap
       vim-tmux-navigator
+      yank
       {
         plugin = tmux-floax;
         extraConfig = ''
@@ -38,27 +27,23 @@
         '';
       }
       {
-        plugin = yank;
+        plugin = kanagawa;
         extraConfig = ''
-          bind-key -T copy-mode-vi v send-keys -X begin-selection
-          bind-key -T copy-mode-vi C-v send-keys -X rectangle-toggle
-          bind-key -T copy-mode-vi y send-keys -X copy-selection-and-cancel
-        '';
-      }
-      {
-        plugin = resurrect;
-        extraConfig = "set -g @resurrect-strategy-nvim 'session'";
-      }
-      {
-        plugin = continuum;
-        extraConfig = ''
-          set -g @continuum-restore 'on'
-          set -g @continuum-save-interval '60' # minutes
+          set -g @kanagawa-theme 'dragon'
+          set -g @kanagawa-refresh-rate 60
+          set -g @kanagawa-show-left-icon window
+          set -g @kanagawa-show-battery true
+          set -g @kanagawa-show-powerline true
+          set -g @kanagawa-show-location false
         '';
       }
     ];
 
     extraConfig = ''
+      # TODO: this should only run on macos
+      # sensible plugin assumes $SHELL is /bin/sh
+      set-option -g default-command "${lib.getExe' pkgs.reattach-to-user-namespace "reattach-to-user-namespace"} -l $SHELL"
+
       # split windows on the current path
       unbind %
       unbind '"'
@@ -78,7 +63,10 @@
       set-option -sa terminal-features ',xterm-256color:RGB'
 
       # default layout
-      set-hook -g after-new-window 'split-window -v -p 20'
+      # set-hook -g after-new-window 'split-window -v -p 20'
+
+      # transparent please
+      set -g window-style 'fg=colour250,bg=default'
     '';
   };
 }

+ 0 - 4
home/features/cli/yazi.nix

@@ -1,4 +0,0 @@
-{
-  # TODO: add this theme at some point: https://github.com/catppuccin/yazi/tree/main
-  programs.yazi.enable = true;
-}

+ 0 - 6
home/features/cli/zoxide.nix

@@ -1,6 +0,0 @@
-{
-  programs.zoxide.enable = true;
-  programs.zoxide.options = [
-    "--cmd cd"
-  ];
-}

+ 0 - 6
home/features/cli/zsh.nix

@@ -1,6 +0,0 @@
-{
-  programs.zsh = {
-    enable = true;
-    shellAliases = import ./shell-aliases.nix;
-  };
-}

+ 9 - 8
home/features/core.nix

@@ -1,10 +1,8 @@
-{
-  pkgs,
-  outputs,
-  lib,
-  ...
-}:
-{
+{ pkgs
+, outputs
+, lib
+, ...
+}: {
   imports = [
     # INFO: this is shared between home-manager, nixos, and darwin
     outputs.modules.global.nix-config
@@ -17,7 +15,10 @@
     enableNixpkgsReleaseCheck = false;
 
     username = "thomas";
-    homeDirectory = if pkgs.stdenv.isDarwin then "/Users/thomas" else "/home/thomas";
+    homeDirectory =
+      if pkgs.stdenv.isDarwin
+      then "/Users/thomas"
+      else "/home/thomas";
 
     packages = with pkgs; [
       cachix

+ 7 - 105
home/features/desktop/aerospace.nix

@@ -1,42 +1,14 @@
-{ pkgs, config, lib, ... }:
-
+{ pkgs
+, config
+, lib
+, ...
+}:
 let
   cfg = config.programs.aerospace;
-  aerospace = "${pkgs.lib.meta.getExe cfg.package}";
-  tmux = "${pkgs.lib.meta.getExe config.programs.tmux.package}";
-
-  aerospace-focus-pkg = pkgs.writeShellScriptBin "aerospace-focus" ''
-    direction="$1"
-
-    if [[ -n "$(${aerospace} list-windows --focused | grep tmux)" ]]; then
-      tmux_dir=""
-
-      case "$direction" in
-        left) tmux_dir="L" ;;
-        down) tmux_dir="D" ;;
-        up) tmux_dir="U" ;;
-        right) tmux_dir="R" ;;
-      esac
-
-      if [[ -n "$tmux_dir" ]]; then
-        ret=$(${tmux} run "#{at_edge} $tmux_dir")
-
-        if [[ $ret -eq 1 ]]; then
-          ${aerospace} focus "$direction"
-        else
-          ${tmux} select-pane "-$tmux_dir"
-        fi
-      fi
-    fi
-
-    ${aerospace} focus "$direction"
-  '';
-
-  aerospace-focus = "${pkgs.lib.meta.getExe aerospace-focus-pkg}";
+  aerospace-focus = "${lib.getExe pkgs.aerospace-tmux-focus}";
 in
-
 {
-  home.packages = [ aerospace-focus-pkg ];
+  home.packages = [ pkgs.aerospace-tmux-focus ];
 
   launchd.agents.aerospace = {
     enable = lib.mkForce true;
@@ -55,15 +27,6 @@ in
     userSettings = {
       start-at-login = true;
 
-      gaps = {
-        inner.horizontal = 10;
-        inner.vertical = 10;
-        outer.left = 10;
-        outer.bottom = 10;
-        outer.top = 10;
-        outer.right = 10;
-      };
-
       mode.main.binding = {
         alt-1 = "workspace 1";
         alt-2 = "workspace 2";
@@ -92,8 +55,6 @@ in
         alt-shift-s = "move-node-to-workspace S";
         alt-shift-v = "move-node-to-workspace V";
 
-        alt-shift-f = "fullscreen";
-
         # focus between windows
         ctrl-h = "exec-and-forget ${aerospace-focus} left";
         ctrl-l = "exec-and-forget ${aerospace-focus} right";
@@ -109,72 +70,13 @@ in
         alt-shift-minus = "resize smart -50";
         alt-shift-equal = "resize smart +50";
 
-        alt-tab = "workspace-back-and-forth";
-        alt-shift-tab = "move-workspace-to-monitor --wrap-around next";
-
         alt-shift-semicolon = "mode service";
 
         alt-slash = "layout tiles horizontal vertical";
         alt-comma = "layout accordion horizontal vertical";
       };
 
-      mode.service.binding = {
-        esc = [
-          "reload-config"
-          "mode main"
-        ];
-        r = [
-          "flatten-workspace-tree"
-          "mode main"
-        ];
-        f = [
-          "layout floating tiling"
-          "mode main"
-        ];
-        backspace = [
-          "close-all-windows-but-current"
-          "mode main"
-        ];
-
-        alt-shift-h = [
-          "join-with left"
-          "mode main"
-        ];
-        alt-shift-j = [
-          "join-with down"
-          "mode main"
-        ];
-        alt-shift-k = [
-          "join-with up"
-          "mode main"
-        ];
-        alt-shift-l = [
-          "join-with right"
-          "mode main"
-        ];
-      };
-
       on-window-detected = [
-        # {
-        #   "if".app-id = "org.whispersystems.signal-desktop";
-        #   check-further-callbacks = false;
-        #   run = [ "move-node-to-workspace S" ];
-        # }
-        # {
-        #   "if".app-id = "com.apple.finder";
-        #   check-further-callbacks = false;
-        #   run = [ "move-node-to-workspace E" ];
-        # }
-        # {
-        #   "if".app-id = "com.apple.mail";
-        #   check-further-callbacks = false;
-        #   run = [ "move-node-to-workspace M" ];
-        # }
-        # {
-        #   "if".app-id = "com.mitchellh.ghostty";
-        #   check-further-callbacks = false;
-        #   run = [ "move-node-to-workspace T" ];
-        # }
         # disable on "Picture-in-Picture"
         {
           check-further-callbacks = false;

+ 0 - 185
home/features/desktop/alacritty.nix

@@ -1,185 +0,0 @@
-{ pkgs, ... }:
-{
-  programs.alacritty = {
-    enable = true;
-
-    settings = {
-      env = {
-        LC_ALL = "en_US.UTF-8";
-        LC_CTYPE = "en_US.UTF-8";
-        TERM = "xterm-256color";
-      };
-
-      font = {
-        normal = {
-          family = "FiraCode Nerd Font";
-          style = "Regular";
-        };
-        bold = {
-          family = "FiraCode Nerd Font";
-          style = "Bold";
-        };
-        italic = {
-          family = "FiraCode Nerd Font";
-          style = "Italic";
-        };
-        bold_italic = {
-          family = "FiraCode Nerd Font";
-          style = "Bold Italic";
-        };
-        size = 11.0;
-      };
-
-      colors = {
-        primary = {
-          background = "#303446";
-          foreground = "#c6d0f5";
-          dim_foreground = "#838ba7";
-          bright_foreground = "#c6d0f5";
-        };
-
-        cursor = {
-          text = "#303446";
-          cursor = "#f2d5cf";
-        };
-
-        vi_mode_cursor = {
-          text = "#303446";
-          cursor = "#babbf1";
-        };
-
-        search.matches = {
-          foreground = "#303446";
-          background = "#a5adce";
-        };
-
-        search.focused_match = {
-          foreground = "#303446";
-          background = "#a6d189";
-        };
-
-        footer_bar = {
-          foreground = "#303446";
-          background = "#a5adce";
-        };
-
-        hints.start = {
-          foreground = "#303446";
-          background = "#e5c890";
-        };
-
-        hints.end = {
-          foreground = "#303446";
-          background = "#a5adce";
-        };
-
-        selection = {
-          text = "#303446";
-          background = "#f2d5cf";
-        };
-
-        normal = {
-          black = "#51576d";
-          red = "#e78284";
-          green = "#a6d189";
-          yellow = "#e5c890";
-          blue = "#8caaee";
-          magenta = "#f4b8e4";
-          cyan = "#81c8be";
-          white = "#b5bfe2";
-        };
-
-        bright = {
-          black = "#626880";
-          red = "#e78284";
-          green = "#a6d189";
-          yellow = "#e5c890";
-          blue = "#8caaee";
-          magenta = "#f4b8e4";
-          cyan = "#81c8be";
-          white = "#a5adce";
-        };
-
-        # indexed_colors = {
-        #   index = 16;
-        #   color = "#ef9f76";
-        # };
-        #
-        # indexed_colors = {
-        #   index = 17;
-        #   color = "#f2d5cf";
-        # };
-      };
-
-      bell = {
-        animation = "EaseOutExpo";
-        duration = 400;
-        color = "#ffffff";
-      };
-
-      window = {
-        padding = {
-          x = 12;
-          y = 12;
-        };
-        opacity = 0.8;
-      };
-
-      terminal.shell = {
-        program = "${pkgs.fish}/bin/fish";
-        args = [ "--login" ];
-      };
-
-      keyboard.bindings = [
-        {
-          key = "Space";
-          mods = "Shift";
-          mode = "~Search";
-          action = "ToggleViMode";
-        }
-
-        # TODO: figure out why I set these
-        # { key = "Up"; mods = "Alt"; chars = "\x1b[1;5A"; }
-        # { key = "Down"; mods = "Alt"; chars = "\x1b[1;5B"; }
-        # { key = "Left"; mods = "Alt"; chars = "\x1bb"; }
-        # { key = "Right"; mods = "Alt"; chars = "\x1bf"; }
-        # { key = "A"; mods = "Alt"; chars = "\x1ba"; }
-        # { key = "B"; mods = "Alt"; chars = "\x1bb"; }
-        # { key = "C"; mods = "Alt"; chars = "\x1bc"; }
-        # { key = "D"; mods = "Alt"; chars = "\x1bd"; }
-        # { key = "E"; mods = "Alt"; chars = "\x1be"; }
-        # { key = "F"; mods = "Alt"; chars = "\x1bf"; }
-        # { key = "G"; mods = "Alt"; chars = "\x1bg"; }
-        # { key = "H"; mods = "Alt"; chars = "\x1bh"; }
-        # { key = "I"; mods = "Alt"; chars = "\x1bi"; }
-        # { key = "J"; mods = "Alt"; chars = "\x1bj"; }
-        # { key = "K"; mods = "Alt"; chars = "\x1bk"; }
-        # { key = "L"; mods = "Alt"; chars = "\x1bl"; }
-        # { key = "M"; mods = "Alt"; chars = "\x1bm"; }
-        # { key = "N"; mods = "Alt"; chars = "\x1bn"; }
-        # { key = "O"; mods = "Alt"; chars = "\x1bo"; }
-        # { key = "P"; mods = "Alt"; chars = "\x1bp"; }
-        # { key = "Q"; mods = "Alt"; chars = "\x1bq"; }
-        # { key = "R"; mods = "Alt"; chars = "\x1br"; }
-        # { key = "S"; mods = "Alt"; chars = "\x1bs"; }
-        # { key = "T"; mods = "Alt"; chars = "\x1bt"; }
-        # { key = "U"; mods = "Alt"; chars = "\x1bu"; }
-        # { key = "V"; mods = "Alt"; chars = "\x1bv"; }
-        # { key = "W"; mods = "Alt"; chars = "\x1bw"; }
-        # { key = "X"; mods = "Alt"; chars = "\x1bx"; }
-        # { key = "Y"; mods = "Alt"; chars = "\x1by"; }
-        # { key = "Z"; mods = "Alt"; chars = "\x1bz"; }
-        # { key = "Key0"; mods = "Alt"; chars = "º"; }
-        # { key = "Key1"; mods = "Alt"; chars = "¡"; }
-        # { key = "Key2"; mods = "Alt"; chars = "€"; }
-        # { key = "Key3"; mods = "Alt"; chars = "#"; }
-        # { key = "Key4"; mods = "Alt"; chars = "¢"; }
-        # { key = "Key5"; mods = "Alt"; chars = "∞"; }
-        # { key = "Key6"; mods = "Alt"; chars = "§"; }
-        # { key = "Key7"; mods = "Alt"; chars = "¶"; }
-        # { key = "Key8"; mods = "Alt"; chars = "•"; }
-        # { key = "Key9"; mods = "Alt"; chars = "ª"; }
-      ];
-    };
-  };
-}

+ 3 - 2
home/features/desktop/default.nix

@@ -1,10 +1,11 @@
 {
   imports = [
     ./aerospace.nix
-    ./alacritty.nix
     ./fonts.nix
     ./ghostty.nix
-    ./syncthing.nix
     ./yubikey.nix
+    ./zen-browser.nix
   ];
+
+  services.syncthing.enable = true;
 }

+ 1 - 2
home/features/desktop/fonts.nix

@@ -1,5 +1,4 @@
-{ pkgs, ... }:
-{
+{ pkgs, ... }: {
   fonts.fontconfig.enable = true;
 
   home.packages = with pkgs; [

+ 23 - 69
home/features/desktop/ghostty.nix

@@ -1,102 +1,56 @@
-{
-  pkgs,
-  config,
-  lib,
-  ...
+{ pkgs
+, config
+, lib
+, ...
 }:
-
 let
-  ghosttyCatppuccinSrc = pkgs.fetchFromGitHub {
-    owner = "catppuccin";
-    repo = "ghostty";
-    rev = "9e38fc2";
-    sha256 = "sha256-RlgTeBkjEvZpkZbhIss3KxQcvt0goy4WU+w9d2XCOnw=";
+  kanagawaSrc = pkgs.fetchFromGitHub {
+    owner = "rebelot";
+    repo = "kanagawa.nvim";
+    rev = "master";
+    sha256 = "sha256-i54hTf4AEFTiJb+j5llC5+Xvepj43DiNJSq0vPZCIAg=";
   };
 in
-
 {
   xdg.configFile = {
-    "ghostty/themes/catppuccin-frappe.conf".text =
+    "ghostty/themes/kanagawa-dragon".text =
       lib.strings.fileContents
-        (ghosttyCatppuccinSrc + "/themes/catppuccin-frappe.conf");
-    
-    "ghostty/themes/catppuccin-latte.conf".text =
-      lib.strings.fileContents
-        (ghosttyCatppuccinSrc + "/themes/catppuccin-latte.conf");
+        (kanagawaSrc + "/extras/ghostty/kanagawa-dragon");
 
-    "ghostty/themes/catppuccin-macchiato.conf".text =
+    "ghostty/themes/kanagawa-lotus".text =
       lib.strings.fileContents
-        (ghosttyCatppuccinSrc + "/themes/catppuccin-macchiato.conf");
+        (kanagawaSrc + "/extras/ghostty/kanagawa-lotus");
 
-    "ghostty/themes/catppuccin-mocha.conf".text =
+    "ghostty/themes/kanagawa-wave".text =
       lib.strings.fileContents
-        (ghosttyCatppuccinSrc + "/themes/catppuccin-mocha.conf");
+        (kanagawaSrc + "/extras/ghostty/kanagawa-wave");
   };
 
   programs.ghostty = {
     enable = true;
-    package = null;
+    # Ghostty is a terminal emulator for macOS, it is not available in Nixpkgs
+    # TODO: https://github.com/NixOS/nixpkgs/blob/76efb9f313b326ed24dfae33ff0496a6df370e5a/pkgs/by-name/gh/ghostty/package.nix#L192
+    package = null; # installed via brew cask
 
     installBatSyntax = false;
     installVimSyntax = false;
 
-    enableBashIntegration = true;
-    enableZshIntegration = true;
     enableFishIntegration = true;
 
-    themes = {
-      iceberg-dark = {
-        background = "161821";
-        foreground = "c6c8d1";
-
-        selection-background = "1e2132";
-        selection-foreground = "c6c8d1";
-
-        cursor-color = "#d2d4de";
-
-        palette = [
-          # black
-          "0=#161821"
-          "8=#6b7089"
-          # red
-          "1=#e27878"
-          "9=#e98989"
-          # green
-          "2=#b4be82"
-          "10=#c0ca8e"
-          # yellow
-          "3=#e2a478"
-          "11=#e9b189"
-          # blue
-          "4=#84a0c6"
-          "12=#91acd1"
-          # magenta
-          "5=#a093c7"
-          "13=#ada0d3"
-          # cyan
-          "6=#89b8c2"
-          "14=#95c4ce"
-          # white
-          "7=#c6c8d1"
-          "15=#d2d4de"
-        ];
-      };
-    };
-
     settings = {
-      command = "${pkgs.lib.meta.getExe config.programs.fish.package}";
+      command = "${lib.getExe config.programs.fish.package}";
 
       background-opacity = 0.9;
       font-family = "FiraCode Nerd Font";
-      font-size = 11.0;
+      font-size = 16.0;
 
       macos-titlebar-style = "hidden";
-      theme = "catppuccin-mocha";
+      theme = "kanagawa-dragon";
 
       window-padding-balance = true;
       window-padding-color = "extend";
-      window-padding-x = 5;
-      window-padding-y = 0;
+      window-padding-x = 10;
+      window-padding-y = "10,0";
       window-theme = "ghostty";
     };
   };

+ 0 - 440
home/features/desktop/logseq.nix

@@ -1,440 +0,0 @@
-{ pkgs, ... }:
-{
-  # imports = [
-  #   outputs.modules.home-manager.logseq
-  # ];
-
-  # programs.logseq = {
-  #   enable = true;
-  #
-  #   settings = {
-  #     meta.version = 1;
-  #   };
-  # };
-
-  # home.packages = [ pkgs.logseq ];
-
-  home.file.".logseq/config/config.edn".text = ''
-    {:meta/version 1
-
-     ;; Set the preferred format.
-     ;; Available options:
-     ;; - Markdown (default)
-     ;; - Org
-     ;; :preferred-format "Markdown"
-
-     ;; Set the preferred workflow style.
-     ;; Available options:
-     ;; - :now for NOW/LATER style (default)
-     ;; - :todo for TODO/DOING style
-     :preferred-workflow :todo
-
-     ;; Exclude directories/files.
-     ;; Example usage:
-     ;; :hidden ["/archived" "/test.md" "../assets/archived"]
-     :hidden []
-
-     ;; Define the default journal page template.
-     ;; Enter the template name between the quotes.
-     :default-templates
-     {:journals ""}
-
-     ;; Set a custom date format for the journal page title.
-     ;; Default value: "MMM do, yyyy"
-     ;; e.g., "Jan 19th, 2038"
-     ;; Example usage e.g., "Tue 19th, Jan 2038"
-     :journal/page-title-format "yyyy/MM/dd"
-
-     ;; Specify the journal filename format using a valid date format string.
-     ;; !Warning:
-     ;;   This configuration is not retroactive and affects only new journals.
-     ;;   To show old journal files in the app, manually rename the files in the
-     ;;   journal directory to match the new format.
-     ;; Default value: "yyyy_MM_dd"
-     ;; :journal/file-name-format "yyyy_MM_dd"
-
-     ;; Enable tooltip preview on hover.
-     ;; Default value: true
-     :ui/enable-tooltip? true
-
-     ;; Display brackets [[]] around page references.
-     ;; Default value: true
-     ;; :ui/show-brackets? true
-
-     ;; Display all lines of a block when referencing ((block)).
-     ;; Default value: false
-     :ui/show-full-blocks? false
-
-     ;; Automatically expand block references when zooming in.
-     ;; Default value: true
-     :ui/auto-expand-block-refs? true
-
-     ;; Enable Block timestamps.
-     ;; Default value: false
-     :feature/enable-block-timestamps? false
-
-     ;; Disable accent marks when searching.
-     ;; After changing this setting, rebuild the search index by pressing (^C ^S).
-     ;; Default value: true
-     :feature/enable-search-remove-accents? true
-
-     ;; Enable journals.
-     ;; Default value: true
-     ;; :feature/enable-journals? true
-
-     ;; Enable flashcards.
-     ;; Default value: true
-     :feature/enable-flashcards? false
-
-     ;; Enable whiteboards.
-     ;; Default value: true
-     :feature/enable-whiteboards? false
-
-     ;; Disable the journal's built-in 'Scheduled tasks and deadlines' query.
-     ;; Default value: false
-     ;; :feature/disable-scheduled-and-deadline-query? false
-
-     ;; Specify the number of days displayed in the future for
-     ;; the 'scheduled tasks and deadlines' query.
-     ;; Example usage:
-     ;; Display all scheduled and deadline blocks for the next 14 days:
-     ;; :scheduled/future-days 14
-     ;; Default value: 7
-     ;; :scheduled/future-days 7
-
-     ;; Specify the first day of the week.
-     ;; Available options:
-     ;;  - integer from 0 to 6 (Monday to Sunday)
-     ;; Default value: 6 (Sunday)
-     :start-of-week 6
-
-     ;; Specify a custom CSS import.
-     ;; This option takes precedence over the local `logseq/custom.css` file.
-     ;; Example usage:
-     ;; :custom-css-url "@import url('https://cdn.jsdelivr.net/gh/dracula/logseq@master/custom.css');"
-
-     ;; Specify a custom JS import.
-     ;; This option takes precedence over the local `logseq/custom.js` file.
-     ;; Example usage:
-     ;; :custom-js-url "https://cdn.logseq.com/custom.js"
-
-     ;; Set a custom Arweave gateway
-     ;; Default gateway: https://arweave.net
-     ;; :arweave/gateway "https://arweave.net"
-
-     ;; Set bullet indentation when exporting
-     ;; Available options:
-     ;;  - `:eight-spaces` as eight spaces
-     ;;  - `:four-spaces` as four spaces
-     ;;  - `:two-spaces` as two spaces
-     ;;  - `:tab` as a tab character (default)
-     :export/bullet-indentation :two-spaces
-
-     ;; Publish all pages within the Graph
-     ;; Regardless of whether individual pages have been marked as public.
-     ;; Default value: false
-     ;; :publishing/all-pages-public? false
-
-     ;; Define the default home page and sidebar status.
-     ;; If unspecified, the journal page will be loaded on startup and the right sidebar will stay hidden.
-     ;; The `:page` value represents the name of the page displayed at startup.
-     ;; Available options for `:sidebar` are:
-     ;; - "Contents" to display the Contents page in the right sidebar.
-     ;; - A specific page name to display in the right sidebar.
-     ;; - An array of multiple pages, e.g., ["Contents" "Page A" "Page B"].
-     ;; If `:sidebar` remains unset, the right sidebar will stay hidden.
-     ;; Examples:
-     ;; 1. Set "Changelog" as the home page and display "Contents" in the right sidebar:
-     ;; :default-home {:page "Changelog", :sidebar "Contents"}
-     ;; 2. Set "Jun 3rd, 2021" as the home page without the right sidebar:
-     ;; :default-home {:page "Jun 3rd, 2021"}
-     ;; 3. Set "home" as the home page and display multiple pages in the right sidebar:
-     ;; :default-home {:page "home", :sidebar ["Page A" "Page B"]}
-
-     ;; Set the default location for storing notes.
-     ;; Default value: "pages"
-     ;; :pages-directory "pages"
-
-     ;; Set the default location for storing journals.
-     ;; Default value: "journals"
-     ;; :journals-directory "journals"
-
-     ;; Set the default location for storing whiteboards.
-     ;; Default value: "whiteboards"
-     ;; :whiteboards-directory "whiteboards"
-
-     ;; Enabling this option converts
-     ;; [[Grant Ideas]] to [[file:./grant_ideas.org][Grant Ideas]] for org-mode.
-     ;; For more information, visit https://github.com/logseq/logseq/issues/672
-     ;; :org-mode/insert-file-link? false
-
-     ;; Configure custom shortcuts.
-     ;; Syntax:
-     ;; 1. + indicates simultaneous key presses, e.g., `Ctrl+Shift+a`.
-     ;; 2. A space between keys represents key chords, e.g., `t s` means
-     ;;    pressing `t` followed by `s`.
-     ;; 3. mod refers to `Ctrl` for Windows/Linux and `Command` for Mac.
-     ;; 4. Use false to disable a specific shortcut.
-     ;; 5. You can define multiple bindings for a single action, e.g., ["ctrl+j" "down"].
-     ;; The full list of configurable shortcuts is available at:
-     ;; https://github.com/logseq/logseq/blob/master/src/main/frontend/modules/shortcut/config.cljs
-     ;; Example:
-     ;; :shortcuts
-     ;; {:editor/new-block       "enter"
-     ;;  :editor/new-line        "shift+enter"
-     ;;  :editor/insert-link     "mod+shift+k"
-     ;;  :editor/highlight       false
-     ;;  :ui/toggle-settings     "t s"
-     ;;  :editor/up              ["ctrl+k" "up"]
-     ;;  :editor/down            ["ctrl+j" "down"]
-     ;;  :editor/left            ["ctrl+h" "left"]
-     ;;  :editor/right           ["ctrl+l" "right"]}
-     :shortcuts {}
-
-     ;; Configure the behavior of pressing Enter in document mode.
-     ;; if set to true, pressing Enter will create a new block.
-     ;; Default value: false
-     :shortcut/doc-mode-enter-for-new-block? false
-
-     ;; Block content larger than `block/content-max-length` will not be searchable
-     ;; or editable for performance.
-     ;; Default value: 10000
-     :block/content-max-length 10000
-
-     ;; Display command documentation on hover.
-     ;; Default value: true
-     :ui/show-command-doc? true
-
-     ;; Display empty bullet points.
-     ;; Default value: false
-     :ui/show-empty-bullets? false
-
-     ;; Pre-defined :view function to use with advanced queries.
-     :query/views
-     {:pprint
-      (fn [r] [:pre.code (pprint r)])}
-
-     ;; Advanced queries `:result-transform` function.
-     ;; Transform the query result before displaying it.
-     :query/result-transforms
-     {:sort-by-priority
-      (fn [result] (sort-by (fn [h] (get h :block/priority "Z")) result))}
-
-     ;; The following queries will be displayed at the bottom of today's journal page.
-     ;; The "NOW" query returns tasks with "NOW" or "DOING" status.
-     ;; The "NEXT" query returns tasks with "NOW", "LATER", or "TODO" status.
-     :default-queries
-     {:journals
-      [{:title "🔨 NOW"
-        :query [:find (pull ?h [*])
-                :in $ ?start ?today
-                :where
-                [?h :block/marker ?marker]
-                [(contains? #{"NOW" "DOING"} ?marker)]
-                [?h :block/page ?p]
-                [?p :block/journal? true]
-                [?p :block/journal-day ?d]
-                [(>= ?d ?start)]
-                [(<= ?d ?today)]]
-        :inputs [:14d :today]
-        :result-transform (fn [result]
-                            (sort-by (fn [h]
-                                       (get h :block/priority "Z")) result))
-        :group-by-page? false
-        :collapsed? false}
-       {:title "📅 NEXT"
-        :query [:find (pull ?h [*])
-                :in $ ?start ?next
-                :where
-                [?h :block/marker ?marker]
-                [(contains? #{"NOW" "LATER" "TODO"} ?marker)]
-                [?h :block/page ?p]
-                [?p :block/journal? true]
-                [?p :block/journal-day ?d]
-                [(> ?d ?start)]
-                [(< ?d ?next)]]
-        :inputs [:today :7d-after]
-        :group-by-page? false
-        :collapsed? false}]}
-
-     ;; Add custom commands to the command palette
-     ;; Example usage:
-     ;; :commands
-     ;; [
-     ;;  ["js" "Javascript"]
-     ;;  ["md" "Markdown"]
-     ;;  ]
-     :commands []
-
-     ;; Enable collapsing blocks with titles but no children.
-     ;; By default, only blocks with children can be collapsed.
-     ;; Setting `:outliner/block-title-collapse-enabled?` to true allows collapsing
-     ;; blocks with titles (multiple lines) and content. For example:
-     ;; - block title
-     ;;   block content
-     ;; Default value: false
-     :outliner/block-title-collapse-enabled? false
-
-     ;; Macros replace texts and will make you more productive.
-     ;; Example usage:
-     ;; Change the :macros value below to:
-     ;; {"poem" "Rose is $1, violet's $2. Life's ordered: Org assists you."}
-     ;; input "{{poem red,blue}}"
-     ;; becomes
-     ;; Rose is red, violet's blue. Life's ordered: Org assists you.
-     :macros {}
-
-     ;; Configure the default expansion level for linked references.
-     ;; For example, consider the following block hierarchy:
-     ;; - a [[page]] (level 1)
-     ;;   - b        (level 2)
-     ;;     - c      (level 3)
-     ;;       - d    (level 4)
-     ;;
-     ;; With the default value of level 2, block b will be collapsed.
-     ;; If the level's value is set to 3, block c will be collapsed.
-     ;; Default value: 2
-     :ref/default-open-blocks-level 2
-
-     ;; Configure the threshold for linked references before collapsing.
-     ;; Default value: 100
-     :ref/linked-references-collapsed-threshold 50
-
-     ;; Graph view configuration.
-     ;; Example usage:
-     ;; :graph/settings
-     ;; {:orphan-pages?   true   ; Default value: true
-     ;;  :builtin-pages?  false  ; Default value: false
-     ;;  :excluded-pages? false  ; Default value: false
-     ;;  :journal?        false} ; Default value: false
-
-     ;; Graph view configuration.
-     ;; Example usage:
-     ;; :graph/forcesettings
-     ;; {:link-dist       180    ; Default value: 180
-     ;;  :charge-strength -600   ; Default value: -600
-     ;;  :charge-range    600}   ; Default value: 600
-
-     ;; Favorites to list on the left sidebar
-     :favorites []
-
-     ;; Set flashcards interval.
-     ;; Expected value:
-     ;; - Float between 0 and 1
-     ;; higher values result in faster changes to the next review interval.
-     ;; Default value: 0.5
-     ;; :srs/learning-fraction 0.5
-
-     ;; Set the initial interval after the first successful review of a card.
-     ;; Default value: 4
-     ;; :srs/initial-interval 4
-
-     ;; Hide specific block properties.
-     ;; Example usage:
-     ;; :block-hidden-properties #{:public :icon}
-
-     ;; Create a page for all properties.
-     ;; Default value: true
-     :property-pages/enabled? true
-
-     ;; Properties to exclude from having property pages
-     ;; Example usage:
-     ;; :property-pages/excludelist #{:duration :author}
-
-     ;; By default, property value separated by commas will not be treated as
-     ;; page references. You can add properties to enable it.
-     ;; Example usage:
-     ;; :property/separated-by-commas #{:alias :tags}
-
-     ;; Properties that are ignored when parsing property values for references
-     ;; Example usage:
-     ;; :ignored-page-references-keywords #{:author :website}
-
-     ;; logbook configuration.
-     ;; :logbook/settings
-     ;; {:with-second-support? false ;limit logbook to minutes, seconds will be eliminated
-     ;;  :enabled-in-all-blocks true ;display logbook in all blocks after timetracking
-     ;;  :enabled-in-timestamped-blocks false ;don't display logbook at all
-     ;; }
-
-     ;; Mobile photo upload configuration.
-     ;; :mobile/photo
-     ;; {:allow-editing? true
-     ;;  :quality        80}
-
-     ;; Mobile features options
-     ;; Gestures
-     ;; Example usage:
-     ;; :mobile
-     ;; {:gestures/disabled-in-block-with-tags ["kanban"]}
-
-     ;; Extra CodeMirror options
-     ;; See https://codemirror.net/5/doc/manual.html#config for possible options
-     ;; Example usage:
-     ;; :editor/extra-codemirror-options
-     ;; {:lineWrapping  false  ; Default value: false
-     ;;  :lineNumbers   true   ; Default value: true
-     ;;  :readOnly      false} ; Default value: false
-
-     ;; Enable logical outdenting
-     ;; Default value: false
-     ;; :editor/logical-outdenting? false
-
-     ;; Prefer pasting the file when text and a file are in the clipboard.
-     ;; Default value: false
-     ;; :editor/preferred-pasting-file? false
-
-     ;; Quick capture templates for receiving content from other apps.
-     ;; Each template contains three elements {time}, {text} and {url}, which can be auto-expanded
-     ;; by receiving content from other apps. Note: the {} cannot be omitted.
-     ;; - {time}: capture time
-     ;; - {date}: capture date using current date format, use `[[{date}]]` to get a page reference
-     ;; - {text}: text that users selected before sharing.
-     ;; - {url}: URL or assets path for media files stored in Logseq.
-     ;; You can also reorder them or use only one or two of them in the template.
-     ;; You can also insert or format any text in the template, as shown in the following examples.
-     ;; :quick-capture-templates
-     ;; {:text "[[quick capture]] **{time}**: {text} from {url}"
-     ;;  :media "[[quick capture]] **{time}**: {url}"}
-
-     ;; Quick capture options.
-     ;; - insert-today?   Insert the capture at the end of today's journal page (boolean).
-     ;; - redirect-page?  Redirect to the quick capture page after capturing (boolean).
-     ;; - default-page    The default page to capture to if insert-today? is false (string).
-     ;; :quick-capture-options
-     ;; {:insert-today? false           ;; Default value: true
-     ;;  :redirect-page? false          ;; Default value: false
-     ;;  :default-page "quick capture"} ;; Default page: "quick capture"
-
-     ;; File sync options
-     ;; Ignore these files when syncing, regexp is supported.
-     ;; :file-sync/ignore-files []
-
-     ;; Configure the Enter key behavior for
-     ;; context-aware editing with DWIM (Do What I Mean).
-     ;; context-aware Enter key behavior implies that pressing Enter will
-     ;; have different outcomes based on the context.
-     ;; For instance, pressing Enter within a list generates a new list item,
-     ;; whereas pressing Enter in a block reference opens the referenced block.
-     ;; :dwim/settings
-     ;; {:admonition&src?  true        ;; Default value: true
-     ;;  :markup?          false       ;; Default value: false
-     ;;  :block-ref?       true        ;; Default value: true
-     ;;  :page-ref?        true        ;; Default value: true
-     ;;  :properties?      true        ;; Default value: true
-     ;;  :list?            false}      ;; Default value: false
-
-     ;; Configure the escaping method for special characters in page titles.
-     ;; Warning:
-     ;;   This is a dangerous operation. To modify the setting,
-     ;;   access the 'Filename format' setting and follow the instructions.
-     ;;   Otherwise, You may need to manually rename all affected files and
-     ;;   re-index them on all clients after synchronization.
-     ;;   Incorrect handling may result in messy page titles.
-     ;; Available options:
-     ;;   - :triple-lowbar (default)
-     ;;      ;use triple underscore `___` for slash `/` in page title
-     ;;      ;use Percent-encoding for other invalid characters
-     :file/name-format :triple-lowbar}
-  '';
-}

+ 0 - 3
home/features/desktop/syncthing.nix

@@ -1,3 +0,0 @@
-{
-  services.syncthing.enable = true;
-}

+ 5 - 5
home/features/desktop/yubikey.nix

@@ -1,8 +1,8 @@
-{ lib, pkgs, ... }:
-
-with lib;
-
-let
+{ lib
+, pkgs
+, ...
+}:
+with lib; let
   inherit (pkgs.stdenv.hostPlatform) isLinux;
 in
 {

+ 163 - 4
home/features/desktop/zen-browser.nix

@@ -1,13 +1,172 @@
-{ outputs, ... }:
+{ inputs, pkgs, lib, config, ... }:
+
+let
+  locked = value: {
+    Value = value;
+    Status = "locked";
+  };
+in
+
 {
   imports = [
-    outputs.modules.home-manager.zen-browser
+    inputs.zen-browser.homeModules.twilight
   ];
 
+  programs.zen-browser.policies = {
+    ExtensionSettings = {
+      "{d7742d87-e61d-4b78-b8a1-b469842139fa}" = {
+        install_url = "https://addons.mozilla.org/firefox/downloads/latest/vimium-ff/latest.xpi";
+        installation_mode = "force_installed";
+      };
+
+      "[email protected]" = {
+        install_url = "https://addons.mozilla.org/firefox/downloads/latest/ublock-origin/latest.xpi";
+        installation_mode = "force_installed";
+      };
+    };
+  };
+
   programs.zen-browser = {
     enable = true;
-    profiles.thomas = {
-      isDefault = true;
+
+    # NOTE: Zen Browser seems currently to ignore Enterprise Policies
+    # See: https://github.com/zen-browser/desktop/discussions/2195
+    # All actual configuration is done via Preferences instead
+    policies = {
+      Preferences = builtins.mapAttrs (_: locked) {
+        # Original preferences
+        "browser.tabs.warnOnClose" = false;
+        "media.videocontrols.picture-in-picture.video-toggle.enabled" = true;
+
+        # AutofillAddressEnabled = false
+        "extensions.formautofill.addresses.enabled" = false;
+        "extensions.formautofill.addresses.capture.enabled" = false;
+
+        # AutofillCreditCardEnabled = false  
+        "extensions.formautofill.creditCards.enabled" = false;
+        "extensions.formautofill.creditCards.available" = false;
+
+        # DisableAppUpdate = true
+        "app.update.enabled" = false;
+        "app.update.auto" = false;
+        "app.update.service.enabled" = false;
+
+        # DisableFeedbackCommands = true
+        "browser.chrome.toolbar_tips" = false;
+
+        # DisableFirefoxStudies = true
+        "app.shield.optoutstudies.enabled" = false;
+        "app.normandy.enabled" = false;
+        "app.normandy.api_url" = "";
+
+        # DisablePocket = true
+        "extensions.pocket.enabled" = false;
+        "extensions.pocket.api" = "";
+        "extensions.pocket.oAuthConsumerKey" = "";
+        "extensions.pocket.site" = "";
+
+        # DisableTelemetry = true
+        "toolkit.telemetry.enabled" = false;
+        "toolkit.telemetry.unified" = false;
+        "toolkit.telemetry.server" = "";
+        "toolkit.telemetry.archive.enabled" = false;
+        "toolkit.telemetry.newProfilePing.enabled" = false;
+        "toolkit.telemetry.shutdownPingSender.enabled" = false;
+        "toolkit.telemetry.updatePing.enabled" = false;
+        "toolkit.telemetry.bhrPing.enabled" = false;
+        "toolkit.telemetry.firstShutdownPing.enabled" = false;
+        "datareporting.healthreport.uploadEnabled" = false;
+        "datareporting.policy.dataSubmissionEnabled" = false;
+        "browser.ping-centre.telemetry" = false;
+        "browser.newtabpage.activity-stream.feeds.telemetry" = false;
+        "browser.newtabpage.activity-stream.telemetry" = false;
+
+        # DontCheckDefaultBrowser = true  
+        "browser.shell.checkDefaultBrowser" = false;
+
+        # NoDefaultBookmarks = true
+        "browser.bookmarks.restore_default_bookmarks" = false;
+
+        # OfferToSaveLogins = false
+        "signon.rememberSignons" = false;
+        "signon.autofillForms" = false;
+        "signon.generation.enabled" = false;
+
+        # EnableTrackingProtection (supplementary preferences)
+        "privacy.trackingprotection.enabled" = true;
+        "privacy.trackingprotection.pbmode.enabled" = true;
+        "privacy.trackingprotection.cryptomining.enabled" = true;
+        "privacy.trackingprotection.fingerprinting.enabled" = true;
+        "privacy.trackingprotection.socialtracking.enabled" = true;
+
+        # Additional privacy hardening
+        "browser.safebrowsing.malware.enabled" = false;
+        "browser.safebrowsing.phishing.enabled" = false;
+        "browser.safebrowsing.downloads.enabled" = false;
+        "browser.safebrowsing.downloads.remote.enabled" = false;
+        "network.captive-portal-service.enabled" = false;
+        "network.connectivity-service.enabled" = false;
+      };
     };
   };
+
+  home.activation.zenExtensions = lib.hm.dag.entryAfter [ "writeBoundary" ] ''
+    ZEN_PROFILES_DIR="$HOME/Library/Application Support/zen/Profiles"
+    
+    if [ -d "$ZEN_PROFILES_DIR" ]; then
+      # Extract extension settings from the configuration
+      EXTENSIONS_CONFIG='${builtins.toJSON config.programs.zen-browser.policies.ExtensionSettings}'
+
+      # Find all profile directories that contain zen-themes.json
+      find "$ZEN_PROFILES_DIR" -maxdepth 1 -type d -name "*.*" | while read -r PROFILE_DIR; do
+        # Skip profiles that don't have zen-themes.json
+        if [ ! -f "$PROFILE_DIR/zen-themes.json" ]; then
+          continue
+        fi
+        EXTENSIONS_DIR="$PROFILE_DIR/extensions"
+        mkdir -p "$EXTENSIONS_DIR"
+        
+        echo "Managing extensions for profile: $(basename "$PROFILE_DIR")"
+        
+        # Create a temporary file to track which extensions should exist
+        EXPECTED_EXTENSIONS=$(mktemp)
+        
+        # Parse the JSON configuration and download/update extensions
+        echo "$EXTENSIONS_CONFIG" | ${pkgs.jq}/bin/jq -r 'to_entries[] | select(.value.installation_mode == "force_installed") | "\(.key) \(.value.install_url)"' | while read -r EXTENSION_ID INSTALL_URL; do
+          EXTENSION_FILE="$EXTENSIONS_DIR/$EXTENSION_ID.xpi"
+          
+          # Add to expected extensions list
+          echo "$EXTENSION_ID.xpi" >> "$EXPECTED_EXTENSIONS"
+          
+          echo "Installing extension: $EXTENSION_ID"
+          ${pkgs.curl}/bin/curl -L -o "$EXTENSION_FILE" "$INSTALL_URL"
+          
+          if [ $? -eq 0 ]; then
+            echo "Successfully installed: $EXTENSION_ID"
+          else
+            echo "Failed to install: $EXTENSION_ID"
+            rm -f "$EXTENSION_FILE"
+          fi
+        done
+        
+        # Remove extensions that are no longer in the configuration
+        if [ -f "$EXPECTED_EXTENSIONS" ]; then
+          for EXISTING_XPI in "$EXTENSIONS_DIR"/*.xpi; do
+            if [ -f "$EXISTING_XPI" ]; then
+              BASENAME=$(basename "$EXISTING_XPI")
+              if ! grep -Fxq "$BASENAME" "$EXPECTED_EXTENSIONS"; then
+                echo "Removing unmanaged extension: $BASENAME"
+                rm -f "$EXISTING_XPI"
+              fi
+            fi
+          done
+        fi
+        
+        # Cleanup temporary file
+        rm -f "$EXPECTED_EXTENSIONS"
+      done
+    else
+      echo "Zen Browser profiles directory not found: $ZEN_PROFILES_DIR"
+    fi
+  '';
 }

+ 31 - 0
home/features/nvim/copilot.nix

@@ -0,0 +1,31 @@
+{
+  programs.nixvim = {
+    plugins.copilot-lua.enable = true;
+    plugins.copilot-lua.settings = {
+      suggestion = {
+        enabled = true;
+        auto_trigger = true;
+        accept = false;
+      };
+      panel.enabled = false;
+      filetypes."*" = true;
+    };
+
+    keymaps = [
+      {
+        key = "<S-Tab>";
+        action.__raw = ''
+          function()
+            if require("copilot.suggestion").is_visible() then
+              require("copilot.suggestion").accept()
+            else
+              vim.api.nvim_feedkeys(vim.api.nvim_replace_termcodes("<S-Tab>", true, false, true), "n", false)
+            end
+          end
+        '';
+        mode = "i";
+        options.silent = true;
+      }
+    ];
+  };
+}

+ 109 - 41
home/features/nvim/default.nix

@@ -1,47 +1,115 @@
-{ inputs, lib, pkgs, ... }:
-let
-  # Define `recursiveUpdateMany` if not present
-  recursiveUpdateMany = sets: lib.fold lib.attrsets.recursiveUpdate { } sets;
-
-  # Merge all plugin configurations directly from imports
-  nixvim = recursiveUpdateMany [
-    ({
-      enable = true;
-      defaultEditor = true;
-      vimdiffAlias = true;
-
-      extraPlugins = with pkgs; [
-        (vimUtils.buildVimPlugin rec {
-          pname = "nord.nvim";
-          version = "1.1.0";
-          src = fetchFromGitHub {
-            owner = "gbprod";
-            repo = "nord.nvim";
-            rev = "v${version}";
-            sha256 = "sha256-gSAXDXhxoigWl6qMAJ0yX59bnkOehVA1MADMeHoTHDo=";
-          };
-          meta.homepage = "https://github.com/gbprod/nord.nvim";
-        })
-        vimPlugins.vim-tmux-focus-events
-      ];
-
-      extraConfigLua = ''
-        require("nord").setup({
-          transparent = true,
-        })
-        vim.cmd.colorscheme("nord")
-      '';
-    })
-
-    (import ./keymaps.nix)
-    (import ./options.nix)
-    (import ./plugins.nix)
-  ];
-in
+{ inputs
+, pkgs
+, ...
+}:
 {
   imports = [
     inputs.nixvim.homeManagerModules.nixvim
+
+    ./copilot.nix # copilot plugin
+    ./lsp.nix
+    ./mini.nix # mini.nvim plugin
+    ./telescope.nix # fuzzy find everything
+    ./treesitter.nix # treesitter support
+    ./which-key.nix # keybinding helper
   ];
 
-  programs.nixvim = nixvim;
+  programs.nixvim.plugins = {
+    tmux-navigator.enable = true; # tmux navigation
+    todo-comments.enable = true; # todo comments eg TODO, FIXME, etc
+  };
+
+  programs.nixvim = {
+    enable = true;
+    defaultEditor = true;
+    vimdiffAlias = true;
+
+    extraPlugins = with pkgs; [
+      vimPlugins.kanagawa-nvim
+    ];
+
+    extraConfigLua = ''
+      require("kanagawa").setup({
+        transparent = true,
+      })
+      vim.cmd.colorscheme("kanagawa")
+    '';
+
+    globals.mapleader = " ";
+    globals.maplocalleader = " ";
+    globals.have_nerd_font = true;
+
+    clipboard.register = "unnamedplus";
+
+    opts = {
+      number = true;
+      relativenumber = true;
+      showmode = false;
+      breakindent = true;
+      undofile = true;
+      ignorecase = true;
+      smartcase = true;
+      signcolumn = "yes";
+      updatetime = 250;
+      timeoutlen = 300;
+      splitright = true;
+      splitbelow = true;
+      list = true;
+      listchars = {
+        tab = "» ";
+        trail = "·";
+        nbsp = "␣";
+      };
+      inccommand = "split";
+      cursorline = true;
+      scrolloff = 10;
+      hlsearch = true;
+      swapfile = false;
+      backup = false;
+      conceallevel = 1;
+      laststatus = 3;
+      cmdheight = 0;
+    };
+
+    autoCmd = [
+      {
+        event = "TextYankPost";
+        desc = "Highlight when yanking (copying) text";
+        group = "kickstart-highlight-yank";
+        callback.__raw = ''
+          function()
+            vim.highlight.on_yank()
+          end
+        '';
+      }
+    ];
+
+    autoGroups = {
+      "kickstart-highlight-yank".clear = true;
+    };
+
+    keymaps = [
+      { key = "<Esc>"; action = "<cmd>nohlsearch<CR>"; mode = "n"; }
+      # Diagnostic keymaps
+      # { key = "<leader>q"; action.__raw = "vim.diagnostic.setloclist"; mode = "n"; options.desc = "Open diagnostic [Q]uickfix list"; }
+      # Exit terminal mode in the builtin terminal
+      # { key = "<Esc><Esc>"; action = "<C-\\><C-n>"; mode = "t"; option.desc = "Exit terminal mode"; }
+      # Keybinds to make split navigation easier. TODO: figure out if these work
+      { key = "<C-h>"; action = "<C-w><C-h>"; mode = "n"; options.desc = "Move focus to the left window"; }
+      { key = "<C-l>"; action = "<C-w><C-l>"; mode = "n"; options.desc = "Move focus to the right window"; }
+      { key = "<C-j>"; action = "<C-w><C-j>"; mode = "n"; options.desc = "Move focus to the lower window"; }
+      { key = "<C-k>"; action = "<C-w><C-k>"; mode = "n"; options.desc = "Move focus to the upper window"; }
+      # Move highlighed blocks of code up and down
+      { key = "K"; action = ":m '<-2<CR>gv=gv"; mode = "v"; options.desc = "Move highlighted block up"; }
+      { key = "J"; action = ":m '>+1<CR>gv=gv"; mode = "v"; options.desc = "Move highlighted block down"; }
+
+      { key = "J"; action = "mzJ`z"; mode = "n"; options.desc = "Join lines without losing cursor position"; }
+
+      { key = "<C-d>"; action = "<C-d>zz"; mode = "n"; options.desc = "Scroll down and center cursor"; }
+      { key = "<C-u>"; action = "<C-u>zz"; mode = "n"; options.desc = "Scroll up and center cursor"; }
+
+      { key = "n"; action = "nzzzv"; mode = "n"; options.desc = "Find next and center cursor"; }
+      { key = "N"; action = "Nzzzv"; mode = "n"; options.desc = "Find previous and center cursor"; }
+    ];
+  };
 }

+ 0 - 76
home/features/nvim/keymaps.nix

@@ -1,76 +0,0 @@
-{
-  keymaps = [
-    # clear search highlight on <ESC>
-    {
-      key = "<Esc>";
-      action = "<cmd>nohlsearch<CR>";
-      mode = "n";
-    }
-    # Diagnostic keymaps
-    # { key = "<leader>q"; action.__raw = "vim.diagnostic.setloclist"; mode = "n"; options.desc = "Open diagnostic [Q]uickfix list"; }
-    # Exit terminal mode in the builtin terminal
-    # { key = "<Esc><Esc>"; action = "<C-\\><C-n>"; mode = "t"; option.desc = "Exit terminal mode"; }
-    # Keybinds to make split navigation easier.
-    {
-      key = "<C-h>";
-      action = "<C-w><C-h>";
-      mode = "n";
-      options.desc = "Move focus to the left window";
-    }
-    {
-      key = "<C-l>";
-      action = "<C-w><C-l>";
-      mode = "n";
-      options.desc = "Move focus to the right window";
-    }
-    {
-      key = "<C-j>";
-      action = "<C-w><C-j>";
-      mode = "n";
-      options.desc = "Move focus to the lower window";
-    }
-    {
-      key = "<C-k>";
-      action = "<C-w><C-k>";
-      mode = "n";
-      options.desc = "Move focus to the upper window";
-    }
-    # Move highlighed blocks of code up and down
-    {
-      key = "K";
-      action = ":m '<-2<CR>gv=gv";
-      mode = "v";
-    }
-    {
-      key = "J";
-      action = ":m '>+1<CR>gv=gv";
-      mode = "v";
-    }
-
-    {
-      key = "J";
-      action = "mzJ`z";
-      mode = "n";
-    }
-    {
-      key = "<C-d>";
-      action = "<C-d>zz";
-      mode = "n";
-    }
-    {
-      key = "<C-u>";
-      action = "<C-u>zz";
-      mode = "n";
-    }
-    {
-      key = "n";
-      action = "nzzzv";
-      mode = "n";
-    }
-    {
-      key = "N";
-      action = "Nzzzv";
-      mode = "n";
-    }
-  ];
-}

+ 151 - 150
home/features/nvim/lsp.nix

@@ -1,170 +1,171 @@
 {
-  autoCmd = [
-    {
-      event = "LspAttach";
-      desc = "Keymaps for when LSP is attached";
-      group = "kickstart-lsp-attach";
-      callback.__raw = ''
-        function(event)
-          local map = function(keys, func, desc)
-            vim.keymap.set('n', keys, func, { buffer = event.buf, desc = 'LSP: ' .. desc })
-          end
+  programs.nixvim = {
+    autoCmd = [
+      {
+        event = "LspAttach";
+        desc = "Keymaps for when LSP is attached";
+        group = "kickstart-lsp-attach";
+        callback.__raw = ''
+          function(event)
+            local map = function(keys, func, desc)
+              vim.keymap.set('n', keys, func, { buffer = event.buf, desc = 'LSP: ' .. desc })
+            end
 
-          -- Jump to the definition of the word under your cursor.
-          --  This is where a variable was first declared, or where a function is defined, etc.
-          --  To jump back, press <C-t>.
-          map('gd', require('telescope.builtin').lsp_definitions, '[G]oto [D]efinition')
-
-          -- Find references for the word under your cursor.
-          map('gr', require('telescope.builtin').lsp_references, '[G]oto [R]eferences')
-
-          -- Jump to the implementation of the word under your cursor.
-          --  Useful when your language has ways of declaring types without an actual implementation.
-          map('gI', require('telescope.builtin').lsp_implementations, '[G]oto [I]mplementation')
-
-          -- Jump to the type of the word under your cursor.
-          --  Useful when you're not sure what type a variable is and you want to see
-          --  the definition of its *type*, not where it was *defined*.
-          map('<leader>D', require('telescope.builtin').lsp_type_definitions, 'Type [D]efinition')
-
-          -- Fuzzy find all the symbols in your current document.
-          --  Symbols are things like variables, functions, types, etc.
-          map('<leader>ds', require('telescope.builtin').lsp_document_symbols, '[D]ocument [S]ymbols')
-
-          -- Fuzzy find all the symbols in your current workspace.
-          --  Similar to document symbols, except searches over your entire project.
-          map('<leader>ws', require('telescope.builtin').lsp_dynamic_workspace_symbols, '[W]orkspace [S]ymbols')
-
-          -- Rename the variable under your cursor.
-          --  Most Language Servers support renaming across files, etc.
-          map('<leader>rn', vim.lsp.buf.rename, '[R]e[n]ame')
-
-          -- Execute a code action, usually your cursor needs to be on top of an error
-          -- or a suggestion from your LSP for this to activate.
-          map('<leader>ca', vim.lsp.buf.code_action, '[C]ode [A]ction')
-
-          -- WARN: This is not Goto Definition, this is Goto Declaration.
-          --  For example, in C this would take you to the header.
-          map('gD', vim.lsp.buf.declaration, '[G]oto [D]eclaration')
-
-          -- The following two autocommands are used to highlight references of the
-          -- word under your cursor when your cursor rests there for a little while.
-          --    See `:help CursorHold` for information about when this is executed
-          --
-          -- When you move your cursor, the highlights will be cleared (the second autocommand).
-          local client = vim.lsp.get_client_by_id(event.data.client_id)
-          if client and client.supports_method(vim.lsp.protocol.Methods.textDocument_documentHighlight) then
-            local highlight_augroup = vim.api.nvim_create_augroup('kickstart-lsp-highlight', { clear = false })
-            vim.api.nvim_create_autocmd({ 'CursorHold', 'CursorHoldI' }, {
-              buffer = event.buf,
-              group = highlight_augroup,
-              callback = vim.lsp.buf.document_highlight,
-            })
-
-            vim.api.nvim_create_autocmd({ 'CursorMoved', 'CursorMovedI' }, {
-              buffer = event.buf,
-              group = highlight_augroup,
-              callback = vim.lsp.buf.clear_references,
-            })
-
-            vim.api.nvim_create_autocmd('LspDetach', {
-              group = vim.api.nvim_create_augroup('kickstart-lsp-detach', { clear = true }),
-              callback = function(event2)
-                vim.lsp.buf.clear_references()
-                vim.api.nvim_clear_autocmds { group = 'kickstart-lsp-highlight', buffer = event2.buf }
-              end,
-            })
-          end
+            -- Jump to the definition of the word under your cursor.
+            --  This is where a variable was first declared, or where a function is defined, etc.
+            --  To jump back, press <C-t>.
+            map('gd', require('telescope.builtin').lsp_definitions, '[G]oto [D]efinition')
+
+            -- Find references for the word under your cursor.
+            map('gr', require('telescope.builtin').lsp_references, '[G]oto [R]eferences')
+
+            -- Jump to the implementation of the word under your cursor.
+            --  Useful when your language has ways of declaring types without an actual implementation.
+            map('gI', require('telescope.builtin').lsp_implementations, '[G]oto [I]mplementation')
+
+            -- Jump to the type of the word under your cursor.
+            --  Useful when you're not sure what type a variable is and you want to see
+            --  the definition of its *type*, not where it was *defined*.
+            map('<leader>D', require('telescope.builtin').lsp_type_definitions, 'Type [D]efinition')
+
+            -- Fuzzy find all the symbols in your current document.
+            --  Symbols are things like variables, functions, types, etc.
+            map('<leader>ds', require('telescope.builtin').lsp_document_symbols, '[D]ocument [S]ymbols')
+
+            -- Fuzzy find all the symbols in your current workspace.
+            --  Similar to document symbols, except searches over your entire project.
+            map('<leader>ws', require('telescope.builtin').lsp_dynamic_workspace_symbols, '[W]orkspace [S]ymbols')
+
+            -- Rename the variable under your cursor.
+            --  Most Language Servers support renaming across files, etc.
+            map('<leader>rn', vim.lsp.buf.rename, '[R]e[n]ame')
+
+            -- Execute a code action, usually your cursor needs to be on top of an error
+            -- or a suggestion from your LSP for this to activate.
+            map('<leader>ca', vim.lsp.buf.code_action, '[C]ode [A]ction')
+
+            -- WARN: This is not Goto Definition, this is Goto Declaration.
+            --  For example, in C this would take you to the header.
+            map('gD', vim.lsp.buf.declaration, '[G]oto [D]eclaration')
+
+            -- The following two autocommands are used to highlight references of the
+            -- word under your cursor when your cursor rests there for a little while.
+            --    See `:help CursorHold` for information about when this is executed
+            --
+            -- When you move your cursor, the highlights will be cleared (the second autocommand).
+            local client = vim.lsp.get_client_by_id(event.data.client_id)
+            if client and client.supports_method(vim.lsp.protocol.Methods.textDocument_documentHighlight) then
+              local highlight_augroup = vim.api.nvim_create_augroup('kickstart-lsp-highlight', { clear = false })
+              vim.api.nvim_create_autocmd({ 'CursorHold', 'CursorHoldI' }, {
+                buffer = event.buf,
+                group = highlight_augroup,
+                callback = vim.lsp.buf.document_highlight,
+              })
+
+              vim.api.nvim_create_autocmd({ 'CursorMoved', 'CursorMovedI' }, {
+                buffer = event.buf,
+                group = highlight_augroup,
+                callback = vim.lsp.buf.clear_references,
+              })
+
+              vim.api.nvim_create_autocmd('LspDetach', {
+                group = vim.api.nvim_create_augroup('kickstart-lsp-detach', { clear = true }),
+                callback = function(event2)
+                  vim.lsp.buf.clear_references()
+                  vim.api.nvim_clear_autocmds { group = 'kickstart-lsp-highlight', buffer = event2.buf }
+                end,
+              })
+            end
 
-          -- The following code creates a keymap to toggle inlay hints in your
-          -- code, if the language server you are using supports them
-          --
-          -- This may be unwanted, since they displace some of your code
-          if client and client.supports_method(vim.lsp.protocol.Methods.textDocument_inlayHint) then
-            map('<leader>th', function()
-              vim.lsp.inlay_hint.enable(not vim.lsp.inlay_hint.is_enabled { bufnr = event.buf })
-            end, '[T]oggle Inlay [H]ints')
+            -- The following code creates a keymap to toggle inlay hints in your
+            -- code, if the language server you are using supports them
+            --
+            -- This may be unwanted, since they displace some of your code
+            if client and client.supports_method(vim.lsp.protocol.Methods.textDocument_inlayHint) then
+              map('<leader>th', function()
+                vim.lsp.inlay_hint.enable(not vim.lsp.inlay_hint.is_enabled { bufnr = event.buf })
+              end, '[T]oggle Inlay [H]ints')
+            end
           end
-        end
-      '';
-    }
-  ];
+        '';
+      }
+    ];
 
-  autoGroups = {
-    "kickstart-lsp-attach".clear = true;
-  };
+    autoGroups = {
+      "kickstart-lsp-attach".clear = true;
+    };
 
-  keymaps = [
-    {
-      key = "<C-h>";
-      action.__raw = "vim.lsp.buf.signature_help";
-      mode = "i";
-    }
-  ];
-
-  plugins.lsp = {
-    enable = true;
-
-    keymaps = {
-      diagnostic = {
-        "<leader>vd" = "open_float";
-        "[d" = "goto_next";
-        "]d" = "goto_prev";
-      };
+    keymaps = [
+      {
+        key = "<C-h>";
+        action.__raw = "vim.lsp.buf.signature_help";
+        mode = "i";
+      }
+    ];
+
+    plugins.lsp = {
+      enable = true;
+
+      keymaps = {
+        diagnostic = {
+          "<leader>vd" = "open_float";
+          "[d" = "goto_next";
+          "]d" = "goto_prev";
+        };
 
-      lspBuf = {
-        "<leader>f" = "format";
-        "gd" = "definition";
-        "K" = "hover";
-        "<leader>vws" = "workspace_symbol";
-        "<leader>vca" = "code_action";
-        "<leader>vrr" = "references";
-        "<leader>vrn" = "rename";
+        lspBuf = {
+          "<leader>f" = "format";
+          "gd" = "definition";
+          "K" = "hover";
+          "<leader>vws" = "workspace_symbol";
+          "<leader>vca" = "code_action";
+          "<leader>vrr" = "references";
+          "<leader>vrn" = "rename";
+        };
       };
-    };
 
-    servers = {
-      astro.enable = true;
-      bashls.enable = true;
-
-      denols = {
-        enable = true;
-        extraOptions.init_options = {
-          lint = true;
-          unstable = true;
-          root_dir.__raw = ''
-            require("lspconfig.util").root_pattern("deno.json", "deno.jsonc", "deno.lock")
-          '';
+      servers = {
+        astro.enable = true;
+        bashls.enable = true;
+
+        denols = {
+          enable = true;
+          extraOptions.init_options = {
+            lint = true;
+            unstable = true;
+            root_dir.__raw = ''
+              require("lspconfig.util").root_pattern("deno.json", "deno.jsonc", "deno.lock")
+            '';
+          };
         };
-      };
 
-      gopls.enable = true;
+        gopls.enable = true;
 
-      # elixirls.enable = true;
-      nextls.enable = true;
-      nil_ls.enable = true;
-      tailwindcss.enable = true;
+        nextls.enable = true;
+        nil_ls.enable = true;
+        tailwindcss.enable = true;
 
-      ts_ls = {
-        enable = true;
-        extraOptions = {
-          single_file_support = false;
-          root_dir.__raw = ''
-            function(fname)
-              local util = require("lspconfig.util")
-              local deno_root = util.root_pattern("deno.json", "deno.jsonc", "deno.lock")(fname)
+        ts_ls = {
+          enable = true;
+          extraOptions = {
+            single_file_support = false;
+            root_dir.__raw = ''
+              function(fname)
+                local util = require("lspconfig.util")
+                local deno_root = util.root_pattern("deno.json", "deno.jsonc", "deno.lock")(fname)
 
-              if deno_root then
-                return nil
-              end
+                if deno_root then
+                  return nil
+                end
 
-              return util.root_pattern("package.json", "tsconfig.json", "jsconfig.json", ".git")(fname)
-            end
-          '';
+                return util.root_pattern("package.json", "tsconfig.json", "jsconfig.json", ".git")(fname)
+              end
+            '';
+          };
         };
-      };
 
-      volar.enable = true;
+        volar.enable = true;
+      };
     };
   };
 }

+ 71 - 0
home/features/nvim/mini.nix

@@ -0,0 +1,71 @@
+{
+  programs.nixvim = {
+    plugins.mini.enable = true;
+    plugins.mini.mockDevIcons = true;
+    plugins.mini.modules = {
+      comment = { };
+      diff = { };
+      icons = { };
+      indentscope = { };
+      notify = { };
+      statusline = { };
+
+      starter = {
+        content_hooks = {
+          "__unkeyed-1.adding_bullet" = {
+            __raw = "require('mini.starter').gen_hook.adding_bullet()";
+          };
+          "__unkeyed-2.indexing" = {
+            __raw = "require('mini.starter').gen_hook.indexing('all', { 'Builtin actions' })";
+          };
+          "__unkeyed-3.padding" = {
+            __raw = "require('mini.starter').gen_hook.aligning('center', 'center')";
+          };
+        };
+        evaluate_single = true;
+        header = ''
+
+
+
+
+                                    ░████ ░██                                              
+                                   ░██                                                     
+          ░█████████  ░███████  ░████████ ░██ ░███████       ░███████  ░██░████  ░████████ 
+               ░███  ░██    ░██    ░██    ░██░██    ░██     ░██    ░██ ░███     ░██    ░██ 
+             ░███    ░██    ░██    ░██    ░██░█████████     ░██    ░██ ░██      ░██    ░██ 
+           ░███      ░██    ░██    ░██    ░██░██            ░██    ░██ ░██      ░██   ░███ 
+          ░█████████  ░███████     ░██    ░██ ░███████  ░██  ░███████  ░██       ░█████░██ 
+                                                                                       ░██ 
+                                                                                 ░███████  
+                                                                                           
+
+
+
+        '';
+        items = {
+          "__unkeyed-1.buildtin_actions" = {
+            __raw = "require('mini.starter').sections.builtin_actions()";
+          };
+          "__unkeyed-2.recent_files_current_directory" = {
+            __raw = "require('mini.starter').sections.recent_files(10, false)";
+          };
+          "__unkeyed-3.recent_files" = {
+            __raw = "require('mini.starter').sections.recent_files(10, true)";
+          };
+        };
+      };
+
+      surround = {
+        mappings = {
+          add = "gsa";
+          delete = "gsd";
+          find = "gsf";
+          find_left = "gsF";
+          highlight = "gsh";
+          replace = "gsr";
+          update_n_lines = "gsn";
+        };
+      };
+    };
+  };
+}

+ 0 - 83
home/features/nvim/options.nix

@@ -1,83 +0,0 @@
-{
-  globals.mapleader = " ";
-  globals.maplocalleader = " ";
-  globals.have_nerd_font = true;
-
-  # Make system clipboard work
-  clipboard.register = "unnamedplus";
-
-  opts = {
-    # Make line numbers default
-    number = true;
-    relativenumber = true;
-    # Enable mouse mode, can be useful for resizing splits for example!
-    mouse = "a";
-    # Don't show the mode, since it's already in the status line
-    showmode = false;
-    # Enable break indent
-    breakindent = true;
-    # Save undo history
-    undofile = true;
-    # Case-insensitive searching UNLESS \C or one or more capital letters in the search term
-    ignorecase = true;
-    smartcase = true;
-    # Keep signcolumn on by default
-    signcolumn = "yes";
-    # Decrease update time
-    updatetime = 250;
-    # Decrease mapped sequence wait time
-    # Displays which-key popup sooner
-    timeoutlen = 300;
-    # Configure how new splits should be opened
-    splitright = true;
-    splitbelow = true;
-    # Sets how neovim will display certain whitespace characters in the editor.
-    list = true;
-    listchars = {
-      tab = "» ";
-      trail = "·";
-      nbsp = "␣";
-    };
-    # Preview substitutions live, as you type!
-    inccommand = "split";
-    # Show which line your cursor is on
-    cursorline = true;
-    # Minimal number of screen lines to keep above and below the cursor.
-    scrolloff = 10;
-    # Set highlight on search
-    hlsearch = true;
-    # Disable swapfile and backup
-    swapfile = false;
-    backup = false;
-    # Set's the conceal level
-    conceallevel = 1;
-    # I don't need a status all the time
-    laststatus = 3;
-    # Hide command bar
-    cmdheight = 0;
-
-    # guicursor = "";
-    # incsearch = true;
-    # termguicolors = true;
-    # scrolloff = 8;
-    # isfname = [ "@-@" ];
-    # colorcolumn = "80";
-  };
-
-  autoCmd = [
-    {
-      event = "TextYankPost";
-      desc = "Highlight when yanking (copying) text";
-      group = "kickstart-highlight-yank";
-      callback.__raw = ''
-        function()
-          vim.highlight.on_yank()
-        end
-      '';
-    }
-  ];
-
-  autoGroups = {
-    "kickstart-highlight-yank".clear = true;
-  };
-}

+ 0 - 26
home/features/nvim/plugins.nix

@@ -1,26 +0,0 @@
-{
-  imports = [
-    ./lsp.nix
-    # ./plugins/avante.nix
-    ./plugins/conform.nix
-    ./plugins/comment.nix
-    ./plugins/copilot.nix
-    ./plugins/fidget.nix
-    ./plugins/gitsigns.nix
-    ./plugins/indent-blankline.nix
-    ./plugins/lint.nix
-    ./plugins/mdx.nix
-    ./plugins/mini.nix
-    ./plugins/oil.nix
-
-    # ./plugins/snacks.nix
-
-    ./plugins/telescope.nix
-    ./plugins/tmux.nix
-    ./plugins/todo-comments.nix
-    ./plugins/treesitter.nix
-    ./plugins/web-devicons.nix
-    ./plugins/which-key.nix
-    # ./plugins/zenmode.nix
-  ];
-}

+ 0 - 13
home/features/nvim/plugins/avante.nix

@@ -1,13 +0,0 @@
-{
-  plugins.avante.enable = true;
-  plugins.avante.settings = {
-    hints.enabled = false;
-    provider = "openrouter";
-    vendors.openrouter = {
-      __inherited_from = "openai";
-      endpoint = "https://openrouter.ai/api/v1";
-      api_key_name = "OPENROUTER_API_KEY";
-      model = "moonshotai/kimi-k2:free";
-    };
-  };
-}

+ 0 - 44
home/features/nvim/plugins/cmp.nix

@@ -1,44 +0,0 @@
-{
-  plugins.cmp.enable = true;
-  plugins.cmp.autoEnableSources = true;
-  plugins.cmp.settings.mapping = {
-    "<C-n>" = "cmp.mapping(cmp.mapping.select_next_item(), {'i', 's'})";
-    "<C-p>" = "cmp.mapping(cmp.mapping.select_prev_item(), {'i', 's'})";
-    "<C-b>" = "cmp.mapping.scroll_docs(-4)";
-    "<C-f>" = "cmp.mapping.scroll_docs(4)";
-    "<C-y>" = "cmp.mapping.confirm({ select = true })";
-    "<C-Space>" = "cmp.mapping.complete()";
-    "<C-e>" = "cmp.mapping.close()";
-
-    "<C-l>" = ''
-      cmp.mapping(function()
-        if luasnip.expand_or_locally_jumpable() then
-          luasnip.expand_or_jump()
-        end
-      end, { 'i', 's' })
-    '';
-
-    "<C-h>" = ''
-      cmp.mapping(function()
-        if luasnip.locally_jumpable(-1) then
-          luasnip.jump(-1)
-        end
-      end, { 'i', 's' })
-    '';
-  };
-  plugins.cmp.settings.sources = [
-    { name = "nvim_lsp"; }
-    { name = "luasnip"; }
-    { name = "path"; }
-    { name = "buffer"; }
-    { name = "friendly-snippets"; }
-  ];
-
-  plugins.luasnip.enable = true;
-  plugins.cmp_luasnip.enable = true;
-  plugins.cmp-nvim-lsp.enable = true;
-  plugins.cmp-nvim-lsp-document-symbol.enable = true;
-  plugins.cmp-nvim-lsp-signature-help.enable = true;
-  plugins.cmp-path.enable = true;
-  plugins.friendly-snippets.enable = true;
-}

+ 0 - 3
home/features/nvim/plugins/comment.nix

@@ -1,3 +0,0 @@
-{
-  plugins.comment.enable = true;
-}

+ 0 - 41
home/features/nvim/plugins/conform.nix

@@ -1,41 +0,0 @@
-{
-  keymaps = [
-    {
-      key = "<leader>f";
-      action.__raw = ''
-        function()
-          require('conform').format { async = true, lsp_fallback = true }
-        end
-      '';
-      options.desc = "[F]ormat buffer";
-    }
-  ];
-
-  plugins.conform-nvim = {
-    enable = true;
-    settings.formatters_by_ft = {
-      lua = [ "lua_ls" ];
-      javascript = [
-        [
-          "prettierd"
-          "prettier"
-        ]
-        [
-          "eslint_d"
-          "eslint"
-        ]
-      ];
-      typescript = [
-        [
-          "prettierd"
-          "prettier"
-        ]
-        [
-          "eslint_d"
-          "eslint"
-        ]
-      ];
-    };
-    settings.notify_on_error = false;
-  };
-}

+ 0 - 29
home/features/nvim/plugins/copilot.nix

@@ -1,29 +0,0 @@
-{
-  plugins.copilot-lua.enable = true;
-  plugins.copilot-lua.settings = {
-    suggestion = {
-      enabled = true;
-      auto_trigger = true;
-      accept = false;
-    };
-    panel.enabled = false;
-    filetypes."*" = true;
-  };
-
-  keymaps = [
-    {
-      key = "<S-Tab>";
-      action.__raw = ''
-        function()
-          if require("copilot.suggestion").is_visible() then
-            require("copilot.suggestion").accept()
-          else
-            vim.api.nvim_feedkeys(vim.api.nvim_replace_termcodes("<S-Tab>", true, false, true), "n", false)
-          end
-        end
-      '';
-      mode = "i";
-      options.silent = true;
-    }
-  ];
-}

+ 0 - 32
home/features/nvim/plugins/elixir-tools.nix

@@ -1,32 +0,0 @@
-# { pkgs, ... }:
-{
-  plugins.elixir.enable = false;
-  # plugins.elixir.settings = {
-  #   nextls = {
-  #     enable = true;
-  #     cmd = "nextls";
-  #     init_options = {
-  #       mix_env = "production";
-  #       mix_target = "localhost";
-  #       experimental.completions.enable = true;
-  #       extensions.credo = {
-  #         enable = true;
-  #         cli_options = [];
-  #       };
-  #     };
-  #     # on_attach.__raw = ''
-  #     #   function(client, bufnr)
-  #     #     -- from config
-  #     #   end
-  #     # '';
-  #   };
-  # #   nextls.enable = true;
-  # #   nextls.auto_update = true;
-  # #   elixirls.enable = false;
-  # #   projectionist.enable = false;
-  # };
-  # extraPlugins = with pkgs.vimPlugins; [ elixir-tools-nvim ];
-  # extraConfigLua = ''
-  #   require("elixir").setup()
-  # '';
-}

+ 0 - 3
home/features/nvim/plugins/fidget.nix

@@ -1,3 +0,0 @@
-{
-  plugins.fidget.enable = true;
-}

+ 0 - 22
home/features/nvim/plugins/gitsigns.nix

@@ -1,22 +0,0 @@
-{
-  plugins.gitsigns.enable = true;
-  plugins.gitsigns.settings = {
-    signs = {
-      add = {
-        text = "+";
-      };
-      change = {
-        text = "~";
-      };
-      delete = {
-        text = "_";
-      };
-      topdelete = {
-        text = "‾";
-      };
-      changedelete = {
-        text = "~";
-      };
-    };
-  };
-}

+ 0 - 3
home/features/nvim/plugins/indent-blankline.nix

@@ -1,3 +0,0 @@
-{
-  plugins.indent-blankline.enable = true;
-}

+ 0 - 13
home/features/nvim/plugins/lint.nix

@@ -1,13 +0,0 @@
-{
-  plugins.lint.enable = true;
-  plugins.lint.lintersByFt = {
-    elixir = [ "credo" ];
-  };
-}
-
-# vim.api.nvim_create_autocmd({ "BufEnter", "BufWritePost", "InsertLeave" }, {
-#   group = lint_augroup,
-#   callback = function()
-#     lint.try_lint()
-#   end,
-# })

+ 0 - 25
home/features/nvim/plugins/mdx.nix

@@ -1,25 +0,0 @@
-{
-  filetype.extension.mdx = "mdx";
-
-  plugins.treesitter.languageRegister.markdown = "mdx";
-
-  extraFiles = {
-    # highlighting import statements in markdown
-    "queries/markdown/injections.scm".text = ''
-      ; extends
-      ((inline) @injection.content
-        (#lua-match? @injection.content "^%s*import")
-        (#set! injection.language "typescript"))
-      ((inline) @injection.content
-        (#lua-match? @injection.content "^%s*export")
-        (#set! injection.language "typescript"))
-    '';
-
-    # disable spell check if turned on
-    "queries/markdown/highlights.scm".text = ''
-      ; extends
-      ((inline) @_inline (#lua-match? @_inline "^%s*import")) @nospell
-      ((inline) @_inline (#lua-match? @_inline "^%s*export")) @nospell
-    '';
-  };
-}

+ 0 - 61
home/features/nvim/plugins/mini.nix

@@ -1,61 +0,0 @@
-{
-  plugins.web-devicons.enable = true;
-  plugins.mini.enable = true;
-  plugins.mini.modules = {
-    ai.n_lines = 500;
-
-    starter = {
-      content_hooks = {
-        "__unkeyed-1.adding_bullet" = {
-          __raw = "require('mini.starter').gen_hook.adding_bullet()";
-        };
-        "__unkeyed-2.indexing" = {
-          __raw = "require('mini.starter').gen_hook.indexing('all', { 'Builtin actions' })";
-        };
-        "__unkeyed-3.padding" = {
-          __raw = "require('mini.starter').gen_hook.aligning('center', 'center')";
-        };
-      };
-      evaluate_single = true;
-      header = ''
-        ███╗   ██╗██╗██╗  ██╗██╗   ██╗██╗███╗   ███╗
-        ████╗  ██║██║╚██╗██╔╝██║   ██║██║████╗ ████║
-        ██╔██╗ ██║██║ ╚███╔╝ ██║   ██║██║██╔████╔██║
-        ██║╚██╗██║██║ ██╔██╗ ╚██╗ ██╔╝██║██║╚██╔╝██║
-        ██║ ╚████║██║██╔╝ ██╗ ╚████╔╝ ██║██║ ╚═╝ ██║
-      '';
-      items = {
-        "__unkeyed-1.buildtin_actions" = {
-          __raw = "require('mini.starter').sections.builtin_actions()";
-        };
-        "__unkeyed-2.recent_files_current_directory" = {
-          __raw = "require('mini.starter').sections.recent_files(10, false)";
-        };
-        "__unkeyed-3.recent_files" = {
-          __raw = "require('mini.starter').sections.recent_files(10, true)";
-        };
-        "__unkeyed-4.sessions" = {
-          __raw = "require('mini.starter').sections.sessions(5, true)";
-        };
-      };
-    };
-
-    statusline.section_location.__raw = ''
-      function()
-        return '%2l:%-2v'
-      end
-    '';
-
-    surround = {
-      mappings = {
-        add = "gsa";
-        delete = "gsd";
-        find = "gsf";
-        find_left = "gsF";
-        highlight = "gsh";
-        replace = "gsr";
-        update_n_lines = "gsn";
-      };
-    };
-  };
-}

+ 0 - 14
home/features/nvim/plugins/oil.nix

@@ -1,14 +0,0 @@
-{
-  keymaps = [
-    {
-      key = "-";
-      action = "<cmd>Oil<cr>";
-      mode = "n";
-    }
-  ];
-
-  plugins.oil.enable = true;
-  plugins.oil.settings.keymaps = {
-    "-" = "<cmd>Oil<cr>";
-  };
-}

+ 0 - 3
home/features/nvim/plugins/sleuth.nix

@@ -1,3 +0,0 @@
-{
-  plugins.sleuth.enable = true;
-}

+ 0 - 58
home/features/nvim/plugins/snacks.nix

@@ -1,58 +0,0 @@
-{
-  plugins.snacks = {
-    enable = true;
-    autoLoad = true;
-    settings = {
-      bigfile = {
-        enabled = true;
-      };
-      dashboard = {
-        width = 60;
-        row = null;
-        col = null;
-        pane_gap = 4;
-        autokeys = "1234567890abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";
-
-        sections = [
-          { section = "header"; }
-          {
-            section = "keys";
-            gap = 1;
-          }
-          {
-            icon = " ";
-            title = "Recent Files";
-            section = "recent_files";
-            indent = 2;
-            padding = [
-              2
-              2
-            ];
-          }
-          {
-            icon = " ";
-            title = "Projects";
-            section = "projects";
-            indent = 2;
-            padding = 2;
-          }
-          { section = "startup"; }
-        ];
-      };
-      notifier = {
-        enabled = true;
-        timeout = 3000;
-      };
-      quickfile = {
-        enabled = true;
-      };
-      statuscolumn = {
-        enabled = true;
-      };
-      words = {
-        debounce = 100;
-        enabled = true;
-      };
-    };
-  };
-}

+ 0 - 117
home/features/nvim/plugins/telescope.nix

@@ -1,117 +0,0 @@
-{
-  plugins.telescope = {
-    enable = true;
-
-    settings.pickers.find_files.follow = true;
-
-    extensions.media-files.enable = true;
-    extensions.media-files.settings.find_cmd = "rg";
-
-    extensions.fzf-native.enable = true;
-    extensions.ui-select.enable = true;
-  };
-
-  keymaps = [
-    {
-      mode = "n";
-      key = "<leader>sh";
-      action.__raw = "require('telescope.builtin').help_tags";
-      options.desc = "[S]earch [H]elp";
-    }
-    {
-      mode = "n";
-      key = "<leader>sk";
-      action.__raw = "require('telescope.builtin').keymaps";
-      options.desc = "[S]earch [K]eymaps";
-    }
-    {
-      mode = "n";
-      key = "<leader>sf";
-      action.__raw = "require('telescope.builtin').find_files";
-      options.desc = "[S]earch [F]iles";
-    }
-    {
-      mode = "n";
-      key = "<leader>ss";
-      action.__raw = "require('telescope.builtin').builtin";
-      options.desc = "[S]earch [S]elect Telescope";
-    }
-    {
-      mode = "n";
-      key = "<leader>sw";
-      action.__raw = "require('telescope.builtin').grep_string";
-      options.desc = "[S]earch current [W]ord";
-    }
-    {
-      mode = "n";
-      key = "<leader>sg";
-      action.__raw = "require('telescope.builtin').live_grep";
-      options.desc = "[S]earch by [G]rep";
-    }
-    {
-      mode = "n";
-      key = "<leader>s.";
-      action.__raw = "require('telescope.builtin').oldfiles";
-      options.desc = "[S]earch Recent Files (\".\" for repeat)";
-    }
-    {
-      mode = "n";
-      key = "<leader>sd";
-      action.__raw = "require('telescope.builtin').diagnostics";
-      options.desc = "[S]earch [D]iagnostics";
-    }
-    {
-      mode = "n";
-      key = "<leader>sr";
-      action.__raw = "require('telescope.builtin').resume";
-      options.desc = "[S]earch [R]esume";
-    }
-    {
-      mode = "n";
-      key = "<leader><leader>";
-      action.__raw = "require('telescope.builtin').buffers";
-      options.desc = "[ ] Find existing buffers";
-    }
-
-    {
-      mode = "n";
-      key = "<leader>/";
-      action.__raw = ''
-        function()
-          require('telescope.builtin').current_buffer_fuzzy_find(require('telescope.themes').get_dropdown {
-            winblend = 10,
-            previewer = false,
-          })
-        end
-      '';
-      options.desc = "[/] Fuzzily search in current buffer";
-    }
-
-    {
-      mode = "n";
-      key = "<leader>s/";
-      action.__raw = ''
-        function()
-          require('telescope.builtin').live_grep {
-            grep_open_files = true,
-            prompt_title = 'Live Grep in Open Files',
-          }
-        end
-      '';
-      options.desc = "[S]earch [/] in Open Files";
-    }
-
-    {
-      mode = "n";
-      key = "<leader>sn";
-      action.__raw = ''
-        function()
-          require('telescope.builtin').find_files {
-            cwd = vim.fn.stdpath 'config'
-          }
-        end
-      '';
-      options.desc = "[S]earch [N]eovim files";
-    }
-  ];
-}

+ 0 - 3
home/features/nvim/plugins/tmux.nix

@@ -1,3 +0,0 @@
-{
-  plugins.tmux-navigator.enable = true;
-}

+ 0 - 4
home/features/nvim/plugins/todo-comments.nix

@@ -1,4 +0,0 @@
-{
-  plugins.todo-comments.enable = true;
-  plugins.todo-comments.settings.signs = false;
-}

+ 0 - 3
home/features/nvim/plugins/web-devicons.nix

@@ -1,3 +0,0 @@
-{
-  plugins.web-devicons.enable = true;
-}

+ 0 - 51
home/features/nvim/plugins/which-key.nix

@@ -1,51 +0,0 @@
-{
-  plugins.which-key.enable = true;
-  plugins.which-key.settings.spec = [
-    {
-      __unkeyed-1 = "<leader>c";
-      group = "[C]ode";
-      icon = "󰄄 ";
-    }
-    {
-      __unkeyed-1 = "<leader>d";
-      group = "[D]ocuments";
-      icon = "󰄄 ";
-    }
-    {
-      __unkeyed-1 = "<leader>r";
-      group = "[R]ename";
-      icon = "󰄄 ";
-    }
-    {
-      __unkeyed-1 = "<leader>s";
-      group = "[S]earch";
-      icon = "󰄄 ";
-    }
-    {
-      __unkeyed-1 = "<leader>w";
-      group = "[W]orkspace";
-      icon = "󰄄 ";
-    }
-    {
-      __unkeyed-1 = "<leader>t";
-      group = "[T]oggle";
-      icon = "󰄄 ";
-    }
-    {
-      __unkeyed-1 = "<leader>h";
-      group = "Git [H]unk";
-      icon = "󰄄 ";
-      mode = [
-        "n"
-        "v"
-      ];
-    }
-  ];
-  # { '<leader>c', group = '[C]ode' },
-  # { '<leader>d', group = '[D]ocument' },
-  # { '<leader>r', group = '[R]ename' },
-  # { '<leader>s', group = '[S]earch' },
-  # { '<leader>w', group = '[W]orkspace' },
-  # { '<leader>t', group = '[T]oggle' },
-  # { '<leader>h', group = 'Git [H]unk', mode = { 'n', 'v' } }
-}

+ 0 - 18
home/features/nvim/plugins/zenmode.nix

@@ -1,18 +0,0 @@
-{
-  keymaps = [
-    {
-      key = "<leader>z";
-      action = "<cmd>ZenMode<CR>";
-      options.desc = "[Z]en Mode";
-    }
-  ];
-
-  plugins.zen-mode = {
-    enable = true;
-    settings = {
-      plugins.alacritty.enabled = true;
-      plugins.tmux.enabled = true;
-      window.width = 0.5;
-    };
-  };
-}

+ 69 - 0
home/features/nvim/telescope.nix

@@ -0,0 +1,69 @@
+{
+  programs.nixvim = {
+    plugins.telescope = {
+      enable = true;
+
+      settings.pickers.find_files.follow = true;
+
+      extensions.media-files.enable = true;
+      extensions.media-files.settings.find_cmd = "rg";
+
+      extensions.fzf-native.enable = true;
+      extensions.ui-select.enable = true;
+    };
+
+    keymaps = [
+      { mode = "n"; key = "<leader>sh"; action.__raw = "require('telescope.builtin').help_tags"; options.desc = "[S]earch [H]elp"; }
+      { mode = "n"; key = "<leader>sk"; action.__raw = "require('telescope.builtin').keymaps"; options.desc = "[S]earch [K]eymaps"; }
+      { mode = "n"; key = "<leader>sf"; action.__raw = "require('telescope.builtin').find_files"; options.desc = "[S]earch [F]iles"; }
+      { mode = "n"; key = "<leader>ss"; action.__raw = "require('telescope.builtin').builtin"; options.desc = "[S]earch [S]elect Telescope"; }
+      { mode = "n"; key = "<leader>sw"; action.__raw = "require('telescope.builtin').grep_string"; options.desc = "[S]earch current [W]ord"; }
+      { mode = "n"; key = "<leader>sg"; action.__raw = "require('telescope.builtin').live_grep"; options.desc = "[S]earch by [G]rep"; }
+      { mode = "n"; key = "<leader>s."; action.__raw = "require('telescope.builtin').oldfiles"; options.desc = "[S]earch Recent Files (\".\" for repeat)"; }
+      { mode = "n"; key = "<leader>sd"; action.__raw = "require('telescope.builtin').diagnostics"; options.desc = "[S]earch [D]iagnostics"; }
+      { mode = "n"; key = "<leader>sr"; action.__raw = "require('telescope.builtin').resume"; options.desc = "[S]earch [R]esume"; }
+      { mode = "n"; key = "<leader><leader>"; action.__raw = "require('telescope.builtin').buffers"; options.desc = "[ ] Find existing buffers"; }
+
+      {
+        mode = "n";
+        key = "<leader>/";
+        action.__raw = ''
+          function()
+            require('telescope.builtin').current_buffer_fuzzy_find(require('telescope.themes').get_dropdown {
+              winblend = 10,
+              previewer = false,
+            })
+          end
+        '';
+        options.desc = "[/] Fuzzily search in current buffer";
+      }
+
+      {
+        mode = "n";
+        key = "<leader>s/";
+        action.__raw = ''
+          function()
+            require('telescope.builtin').live_grep {
+              grep_open_files = true,
+              prompt_title = 'Live Grep in Open Files',
+            }
+          end
+        '';
+        options.desc = "[S]earch [/] in Open Files";
+      }
+
+      {
+        mode = "n";
+        key = "<leader>sn";
+        action.__raw = ''
+          function()
+            require('telescope.builtin').find_files {
+              cwd = vim.fn.stdpath 'config'
+            }
+          end
+        '';
+        options.desc = "[S]earch [N]eovim files";
+      }
+    ];
+  };
+}

+ 3 - 6
home/features/nvim/plugins/treesitter.nix → home/features/nvim/treesitter.nix

@@ -1,16 +1,13 @@
-{ pkgs, ... }:
 {
-  plugins.treesitter = {
-    grammarPackages = pkgs.vimPlugins.nvim-treesitter.passthru.allGrammars;
-
+  programs.nixvim.plugins.treesitter = {
     enable = true;
     settings.ensure_installed = "all";
     settings.ignore_install = [ "norg" ];
     settings.highlight.enable = true;
-    settings.highlight.disable = [  ];
+    settings.highlight.disable = [ ];
     settings.incremental_selection.enable = true;
     settings.indent.enable = true;
     nixvimInjections = true;
   };
-  plugins.treesitter-context.enable = true;
+  programs.nixvim.plugins.treesitter-context.enable = true;
 }

+ 22 - 0
home/features/nvim/which-key.nix

@@ -0,0 +1,22 @@
+{
+  programs.nixvim = {
+    plugins.which-key.enable = true;
+    plugins.which-key.settings.spec = [
+      { __unkeyed-1 = "<leader>c"; group = "[C]ode"; icon = "󰄄 "; }
+      { __unkeyed-1 = "<leader>d"; group = "[D]ocuments"; icon = "󰄄 "; }
+      { __unkeyed-1 = "<leader>r"; group = "[R]ename"; icon = "󰄄 "; }
+      { __unkeyed-1 = "<leader>s"; group = "[S]earch"; icon = "󰄄 "; }
+      { __unkeyed-1 = "<leader>w"; group = "[W]orkspace"; icon = "󰄄 "; }
+      { __unkeyed-1 = "<leader>t"; group = "[T]oggle"; icon = "󰄄 "; }
+      {
+        __unkeyed-1 = "<leader>h";
+        group = "Git [H]unk";
+        icon = "󰄄 ";
+        mode = [
+          "n"
+          "v"
+        ];
+      }
+    ];
+  };
+}

+ 4 - 2
hosts/common/default.nix

@@ -1,5 +1,7 @@
-{ pkgs, outputs, ... }:
-{
+{ pkgs
+, outputs
+, ...
+}: {
   imports = [
     outputs.modules.global
 

+ 7 - 5
hosts/common/home-manager.nix

@@ -1,10 +1,12 @@
-{ inputs, outputs, ... }:
+{ inputs
+, outputs
+, ...
+}:
 let
   home-manager-module =
-    if builtins.runCommand "uname" ''{ outFile = "/dev/stdout"; }'' == "Darwin" then
-      inputs.home-manager.darwinModules.home-manager
-    else
-      inputs.home-manager.nixosModules.home-manager;
+    if builtins.runCommand "uname" ''{ outFile = "/dev/stdout"; }'' == "Darwin"
+    then inputs.home-manager.darwinModules.home-manager
+    else inputs.home-manager.nixosModules.home-manager;
 in
 {
   imports = [ home-manager-module ];

+ 6 - 8
hosts/common/nix.nix

@@ -1,11 +1,9 @@
-{
-  lib,
-  pkgs,
-  config,
-  outputs,
-  ...
-}:
-{
+{ lib
+, pkgs
+, config
+, outputs
+, ...
+}: {
   nix = {
     settings = {
       substituters = [

+ 15 - 6
hosts/meili/default.nix

@@ -1,10 +1,12 @@
-{ outputs, pkgs, ... }:
+{ outputs, config, ... }:
 {
-  imports = [
-    outputs.modules.global.nix-config
-    ./system.nix
-    ./software.nix
-  ] ++ (builtins.attrValues outputs.modules.darwin);
+  imports =
+    [
+      outputs.modules.global.nix-config
+      ./system.nix
+      ./software.nix
+    ]
+    ++ (builtins.attrValues outputs.modules.darwin);
 
   # NOTE: might be valuable to put this in it's own file
   # nix.linux-builder = {
@@ -43,6 +45,10 @@
     };
   };
 
+  environment.shells = [
+    config.programs.fish.package
+  ];
+
   # TODO: move into module:
   # system.activationScripts.extraActivation.text = lib.mkAfter ''
   #   # disable spotlight
@@ -60,7 +66,10 @@
   };
 
   users.users.thomas.home = "/Users/thomas";
+  users.users.thomas.shell = config.programs.fish.package;
+  users.groups.nix-users.members = [ "thomas" ];
   ids.gids.nixbld = 350;
+  nix.settings.trusted-users = [ "thomas" ];
 
   networking = {
     hostName = "meili";

+ 1 - 3
hosts/meili/software.nix

@@ -1,5 +1,4 @@
-{ pkgs, outputs, ... }:
-{
+{ pkgs, ... }: {
   # TODO:
   #   - Proton Mail Bridge
   #   - Proton Drive set up home folders
@@ -46,7 +45,6 @@
       # "tor-browser"
       # "utm"
       "vlc"
-      "zen"
       # "whatsapp"
       # "krunkit"
     ];

+ 1 - 2
hosts/modgud/default.nix

@@ -1,5 +1,4 @@
-{ outputs, ... }:
-{
+{ outputs, ... }: {
   imports = [
     ./hardware.nix
 

+ 4 - 2
hosts/modgud/disk.nix

@@ -1,5 +1,7 @@
-{ lib, inputs, ... }:
-{
+{ lib
+, inputs
+, ...
+}: {
   imports = [
     inputs.disko.nixosModules.disko
   ];

+ 4 - 2
hosts/modgud/hardware.nix

@@ -1,5 +1,7 @@
-{ lib, modulesPath, ... }:
-{
+{ lib
+, modulesPath
+, ...
+}: {
   imports = [
     (modulesPath + "/installer/scan/not-detected.nix")
     (modulesPath + "/profiles/qemu-guest.nix")

+ 42 - 25
lib/default.nix

@@ -1,58 +1,76 @@
-{ inputs, outputs }:
+{ inputs
+, outputs
+,
+}:
+
 let
+  inherit (inputs) darwin devenv home-manager nixpkgs;
+  inherit (nixpkgs) lib;
   # Helper to determine if a system is Darwin
   isDarwin = system: builtins.elem "darwin" (builtins.split "-" system);
 
   # Helper to get the appropriate nixpkgs for a system
-  getPkgsForSystem =
-    system:
-    if isDarwin system then
-      inputs.nixpkgs-darwin.legacyPackages.${system}
-    else
-      inputs.nixpkgs.legacyPackages.${system};
+  getPkgsForSystem = system:
+    if isDarwin system
+    then inputs.nixpkgs-darwin.legacyPackages.${system}
+    else inputs.nixpkgs.legacyPackages.${system};
 in
+
 rec {
   mkSystem =
-    {
-      system,
-      nixpkgs ? inputs.nixpkgs,
-      modules ? [ ],
+    { system
+    , nixpkgs ? nixpkgs
+    , modules ? [ ]
+    ,
     }:
-    inputs.nixpkgs.lib.nixosSystem {
+    lib.nixosSystem {
       inherit system modules nixpkgs;
       specialArgs = { inherit inputs outputs; };
     };
 
   mkDarwin =
-    {
-      system,
-      modules ? [ ],
+    { system
+    , modules ? [ ]
+    ,
     }:
-    inputs.darwin.lib.darwinSystem {
+    darwin.lib.darwinSystem {
       inherit system modules;
       specialArgs = { inherit inputs outputs; };
     };
 
   mkHome =
-    {
-      system,
-      modules ? [ ],
+    { system
+    , modules ? [ ]
+    ,
     }:
-    inputs.home-manager.lib.homeManagerConfiguration {
+    home-manager.lib.homeManagerConfiguration {
       inherit modules;
       pkgs = getPkgsForSystem system;
       extraSpecialArgs = { inherit inputs outputs; };
     };
 
-  eachSystem = inputs.nixpkgs.lib.genAttrs [
+  mkDevenvShell = config:
+    eachSystemWithPkgs (
+      { pkgs }:
+      lib.mapAttrs
+        (
+          _name: module:
+            devenv.lib.mkShell {
+              inherit inputs pkgs;
+              modules = [ module ];
+            }
+        )
+        config
+    );
+
+  eachSystem = lib.genAttrs [
     "x86_64-linux"
     "x86_64-darwin"
     "aarch64-linux"
     "aarch64-darwin"
   ];
 
-  eachSystemWithPkgs =
-    f:
+  eachSystemWithPkgs = f:
     eachSystem (
       system:
       f {
@@ -60,8 +78,7 @@ rec {
       }
     );
 
-  print =
-    text:
+  print = text:
     let
       json = builtins.toJSON text;
     in

+ 5 - 12
modules/darwin/networking/remote-login.nix

@@ -1,32 +1,25 @@
-{ config, lib, ... }:
-
-with lib;
-
-let
-
+{ config
+, lib
+, ...
+}:
+with lib; let
   cfg = config.networking;
 
   remoteLogin = optionalString (cfg.remote-login) ''
     systemsetup -setremotelogin on
   '';
-
 in
-
 {
   options = {
-
     networking.remote-login = mkEnableOption "remote login";
-
   };
 
   config = {
-
     system.activationScripts.networking.text = mkIf cfg.remote-login (mkAfter ''
       # enable remote login
       echo "enabling remote login..." >&2
 
       ${remoteLogin}
     '');
-
   };
 }

+ 40 - 45
modules/darwin/security/pam-reattach.nix

@@ -1,17 +1,12 @@
-{
-  config,
-  lib,
-  pkgs,
-  ...
+{ config
+, lib
+, pkgs
+, ...
 }:
-
-with lib;
-
-let
+with lib; let
   cfg = config.security.pam;
 
-  mkPamReattachScript =
-    isEnabled:
+  mkPamReattachScript = isEnabled:
     let
       file = "/etc/pam.d/sudo";
       option = "security.pam.reattach";
@@ -19,49 +14,49 @@ let
     in
     ''
       ${
-        if isEnabled then
-          ''
-            # If enable and in file, remove and re-add in case the store path has
-            # changed
-            if grep '${option}' ${file} > /dev/null; then
-              ${sed} -i '/${option}/d' ${file}
-            fi
+        if isEnabled
+        then ''
+          # If enable and in file, remove and re-add in case the store path has
+          # changed
+          if grep '${option}' ${file} > /dev/null; then
+            ${sed} -i '/${option}/d' ${file}
+          fi
 
-            ${sed} -i '2i\
-            auth       optional       ${pkgs.pam-reattach}/lib/pam/pam_reattach.so ignore_ssh # nix-darwin: ${option}
-            ' ${file}
-          ''
-        else
-          ''
-            # Disable pam_reattach, if added by nix-darwin
-            if grep '${option}' ${file} > /dev/null; then
-              ${sed} -i '/${option}/d' ${file}
-            fi
-          ''
+          ${sed} -i '2i\
+          auth       optional       ${pkgs.pam-reattach}/lib/pam/pam_reattach.so ignore_ssh # nix-darwin: ${option}
+          ' ${file}
+        ''
+        else ''
+          # Disable pam_reattach, if added by nix-darwin
+          if grep '${option}' ${file} > /dev/null; then
+            ${sed} -i '/${option}/d' ${file}
+          fi
+        ''
       }
     '';
 in
-
 {
   options = {
-    security.pam.enablePamReattach = mkEnableOption "" // {
-      description = lib.mdDoc ''
-        Enable pam_reattach sudo authentication with Touch ID in tmux/screen.
+    security.pam.enablePamReattach =
+      mkEnableOption ""
+      // {
+        description = lib.mdDoc ''
+          Enable pam_reattach sudo authentication with Touch ID in tmux/screen.
 
-        When enabled, this option adds the following line to
-        {file}`/etc/pam.d/sudo`:
+          When enabled, this option adds the following line to
+          {file}`/etc/pam.d/sudo`:
 
-        ```
-        auth       optional     pam_reattach.so ignore_ssh
-        ```
+          ```
+          auth       optional     pam_reattach.so ignore_ssh
+          ```
 
-        ::: {.note}
-        macOS resets this file when doing a system update. As such,
-        pam_reattach won't work after a system update
-        until the nix-darwin configuration is reapplied.
-        :::
-      '';
-    };
+          ::: {.note}
+          macOS resets this file when doing a system update. As such,
+          pam_reattach won't work after a system update
+          until the nix-darwin configuration is reapplied.
+          :::
+        '';
+      };
   };
 
   config = {

+ 5 - 6
modules/darwin/system/rosetta.nix

@@ -1,11 +1,10 @@
-{ config, lib, ... }:
-
-with lib;
-
-let
+{ config
+, lib
+, ...
+}:
+with lib; let
   cfg = config.system.rosetta;
 in
-
 {
   options = {
     system.rosetta.enable = mkOption {

+ 6 - 8
modules/global/nix-config.nix

@@ -1,11 +1,9 @@
-{
-  lib,
-  pkgs,
-  config,
-  outputs,
-  ...
-}:
-{
+{ lib
+, pkgs
+, config
+, outputs
+, ...
+}: {
   nix = {
     package = pkgs.nix;
 

+ 1 - 2
modules/home-manager/default.nix

@@ -1,2 +1 @@
-{
-}
+{ }

+ 8 - 3
overlays/default.nix

@@ -1,12 +1,11 @@
-{ inputs, ... }:
-rec {
+{ inputs, ... }: rec {
   # This one brings our custom packages from the 'pkgs' directory
   additions = final: _prev: import ../packages { pkgs = final; };
 
   # This one contains whatever you want to overlay
   # You can change versions, add patches, set compilation flags, anything really.
   # https://nixos.wiki/wiki/Overlays
-  modifications = final: prev: {
+  modifications = _final: prev: {
     # example = prev.example.overrideAttrs (oldAttrs: rec {
     # ...
     # });
@@ -16,6 +15,12 @@ rec {
     kraft = prev.kraft.overrideAttrs (
       old: inputs.nixpkgs.lib.recursiveUpdate old { meta.broken = false; }
     );
+
+    tmuxPlugins =
+      prev.tmuxPlugins
+      // {
+        tmux-select-pane-no-wrap = prev.tmux-select-pane-no-wrap;
+      };
   };
 
   # When applied, the unstable nixpkgs set (declared in the flake inputs) will

+ 33 - 0
packages/aerospace-tmux-focus.nix

@@ -0,0 +1,33 @@
+{ writeShellScriptBin, lib, tmux, aerospace }:
+
+let
+  aerospaceBin = "${lib.getExe aerospace}";
+  tmuxBin = "${lib.getExe tmux}";
+in
+
+writeShellScriptBin "tmux-aerospace-focus" ''
+  direction="$1"
+
+  if [[ -n "$(${aerospaceBin} list-windows --focused | grep tmux)" ]]; then
+    tmux_dir=""
+
+    case "$direction" in
+      left) tmux_dir="L" ;;
+      down) tmux_dir="D" ;;
+      up) tmux_dir="U" ;;
+      right) tmux_dir="R" ;;
+    esac
+
+    if [[ -n "$tmux_dir" ]]; then
+      ret=$(${tmuxBin} run "#{at_edge} $tmux_dir")
+
+      if [[ $ret -eq 1 ]]; then
+        ${aerospaceBin} focus "$direction"
+      else
+        ${tmuxBin} select-pane "-$tmux_dir"
+      fi
+    fi
+  fi
+
+  ${aerospaceBin} focus "$direction"
+''

+ 3 - 7
packages/default.nix

@@ -1,10 +1,6 @@
-{
-  pkgs ? (import <nixpkgs>) { },
-}:
-{
-  # ghostty = pkgs.callPackage ./ghostty/package.nix {};
+{ pkgs ? (import <nixpkgs>) { } }: {
   hello = pkgs.callPackage ./hello.nix { };
   photo-cli = pkgs.callPackage ./photo-cli.nix { };
-  zen-browser = pkgs.callPackage ./zen-browser { };
-  more-tmux-plugins = pkgs.callPackage ./more-tmux-plugins.nix { };
+  tmux-select-pane-no-wrap = pkgs.callPackage ./tmux-select-pane-no-wrap.nix { };
+  aerospace-tmux-focus = pkgs.callPackage ./aerospace-tmux-focus.nix { };
 }

+ 0 - 86
packages/more-tmux-plugins.nix

@@ -1,86 +0,0 @@
-{
-  lib,
-  fetchFromGitHub,
-  pkgs,
-  stdenv,
-  config,
-}:
-
-let
-  rtpPath = "share/tmux-plugins";
-
-  addRtp =
-    path: rtpFilePath: attrs: derivation:
-    derivation
-    // {
-      rtp = "${derivation}/${path}/${rtpFilePath}";
-    }
-    // {
-      overrideAttrs = f: mkTmuxPlugin (attrs // f attrs);
-    };
-
-  mkTmuxPlugin =
-    a@{
-      pluginName,
-      rtpFilePath ? (builtins.replaceStrings [ "-" ] [ "_" ] pluginName) + ".tmux",
-      namePrefix ? "tmuxplugin-",
-      src,
-      unpackPhase ? "",
-      configurePhase ? ":",
-      buildPhase ? ":",
-      addonInfo ? null,
-      preInstall ? "",
-      postInstall ? "",
-      path ? lib.getName pluginName,
-      ...
-    }:
-    if lib.hasAttr "dependencies" a then
-      throw "dependencies attribute is obselete. see NixOS/nixpkgs#118034" # added 2021-04-01
-    else
-      addRtp "${rtpPath}/${path}" rtpFilePath a (
-        stdenv.mkDerivation (
-          a
-          // {
-            pname = namePrefix + pluginName;
-
-            inherit
-              pluginName
-              unpackPhase
-              configurePhase
-              buildPhase
-              addonInfo
-              preInstall
-              postInstall
-              ;
-
-            installPhase = ''
-              runHook preInstall
-
-              target=$out/${rtpPath}/${path}
-              mkdir -p $out/${rtpPath}
-              cp -r . $target
-              if [ -n "$addonInfo" ]; then
-                echo "$addonInfo" > $target/addon-info.json
-              fi
-
-              runHook postInstall
-            '';
-          }
-        )
-      );
-
-in
-rec {
-  inherit mkTmuxPlugin;
-
-  tmux-select-pane-no-wrap = mkTmuxPlugin rec {
-    pluginName = "tmux-select-pane-no-wrap";
-    version = "00add78";
-    src = fetchFromGitHub {
-      owner = "dalejung";
-      repo = pluginName;
-      rev = version;
-      sha256 = "sha256-ot0cHvk1TXvHOw9z+7TLSiHT77jHwvV2PSHcNuhOorQ=";
-    };
-  };
-}

+ 4 - 2
packages/photo-cli.nix

@@ -1,5 +1,7 @@
-{ buildDotnetGlobalTool, lib, ... }:
-
+{ buildDotnetGlobalTool
+, lib
+, ...
+}:
 buildDotnetGlobalTool {
   pname = "photo-cli";
   version = "0.3.3";

+ 15 - 0
packages/tmux-select-pane-no-wrap.nix

@@ -0,0 +1,15 @@
+{ fetchFromGitHub
+, tmuxPlugins
+,
+}:
+tmuxPlugins.mkTmuxPlugin rec {
+  pluginName = "select-pane-no-wrap";
+  version = "00add78";
+  rtpFilePath = "${pluginName}.tmux";
+  src = fetchFromGitHub {
+    owner = "dalejung";
+    repo = "tmux-${pluginName}";
+    rev = version;
+    sha256 = "sha256-ot0cHvk1TXvHOw9z+7TLSiHT77jHwvV2PSHcNuhOorQ=";
+  };
+}