about summary refs log tree commit diff
diff options
context:
space:
mode:
authorAzat Bahawi <azat@bahawi.net>2023-12-03 02:52:28 +0300
committerAzat Bahawi <azat@bahawi.net>2023-12-03 02:52:28 +0300
commitcec9f7acd5e5e365563212c5144394f71dd90b27 (patch)
tree667b308a7241ab2e8f3fa4e2b53cc7888e876c68
parent2023-11-29 (diff)
2023-12-03
Diffstat (limited to '')
-rw-r--r--flake.lock78
-rw-r--r--modules/common/bat.nix1
-rw-r--r--modules/common/common/nix.nix2
-rw-r--r--modules/common/default.nix1
-rw-r--r--modules/common/emacs/default.nix29
-rw-r--r--modules/common/emacs/doom/config.el5
-rw-r--r--modules/common/eza.nix21
-rw-r--r--modules/common/fonts.nix2
-rw-r--r--modules/common/profiles/default.nix2
-rw-r--r--modules/common/profiles/dev/default.nix3
-rw-r--r--modules/darwin/profiles/headful.nix5
-rw-r--r--modules/nixos/common/locale.nix25
-rw-r--r--modules/nixos/default.nix1
-rw-r--r--modules/nixos/dwm.nix66
-rw-r--r--modules/nixos/emacs.nix24
-rw-r--r--modules/nixos/firefox/addons.nix6
-rw-r--r--modules/nixos/fonts.nix8
-rw-r--r--modules/nixos/kde.nix1
-rw-r--r--modules/nixos/loki.nix4
-rw-r--r--modules/nixos/profiles/headful.nix3
-rw-r--r--modules/nixos/soju.nix30
-rw-r--r--modules/nixos/syncthing.nix28
-rw-r--r--modules/nixos/wayland.nix19
-rw-r--r--modules/nixos/x11.nix7
-rw-r--r--nixosConfigurations/eonwe/default.nix1
-rw-r--r--nixosConfigurations/manwe/default.nix29
-rw-r--r--packages/nixfiles.nix10
27 files changed, 236 insertions, 175 deletions
diff --git a/flake.lock b/flake.lock
index 7390826..60fd9cb 100644
--- a/flake.lock
+++ b/flake.lock
@@ -13,11 +13,11 @@
         ]
       },
       "locked": {
-        "lastModified": 1696775529,
-        "narHash": "sha256-TYlE4B0ktPtlJJF9IFxTWrEeq+XKG8Ny0gc2FGEAdj0=",
+        "lastModified": 1701216516,
+        "narHash": "sha256-jKSeJn+7hZ1dZdiH1L+NWUGT2i/BGomKAJ54B9kT06Q=",
         "owner": "ryantm",
         "repo": "agenix",
-        "rev": "daf42cb35b2dc614d1551e37f96406e4c4a2d3e4",
+        "rev": "13ac9ac6d68b9a0896e3d43a082947233189e247",
         "type": "github"
       },
       "original": {
@@ -70,11 +70,11 @@
         ]
       },
       "locked": {
-        "lastModified": 1698052066,
-        "narHash": "sha256-KnSOyt4Ro66kNf2UIVfIy5Qj5idR9+3QrxJmbo3kzrQ=",
+        "lastModified": 1701036929,
+        "narHash": "sha256-5TkAr5a3EoY9/oeO53SU+FRNfOUTpChj7mEW/Ax3T1w=",
         "owner": "dwarfmaster",
         "repo": "arkenfox-nixos",
-        "rev": "f787d60c3308f067d5f68abbe85083f8a169d72c",
+        "rev": "1c9d061a4ef7bf3ce8a5260eaee4acdb3ee097f9",
         "type": "github"
       },
       "original": {
@@ -147,11 +147,11 @@
         ]
       },
       "locked": {
-        "lastModified": 1699867978,
-        "narHash": "sha256-+arl45HUOcBdKiRGrKXZYXDyBQ6MQGkYPZa/28f6Yzo=",
+        "lastModified": 1700795494,
+        "narHash": "sha256-gzGLZSiOhf155FW7262kdHo2YDeugp3VuIFb4/GGng0=",
         "owner": "LnL7",
         "repo": "nix-darwin",
-        "rev": "e67f2bf515343da378c3f82f098df8ca01bccc5f",
+        "rev": "4b9b83d5a92e8c1fbfd8eb27eda375908c11ec4d",
         "type": "github"
       },
       "original": {
@@ -246,11 +246,11 @@
         ]
       },
       "locked": {
-        "lastModified": 1694102001,
-        "narHash": "sha256-vky6VPK1n1od6vXbqzOXnekrQpTL4hbPAwUhT5J9c9E=",
+        "lastModified": 1660459072,
+        "narHash": "sha256-8DFJjXG8zqoONA1vXtgeKXy68KdJL5UaXR8NtVMUbx8=",
         "owner": "hercules-ci",
         "repo": "gitignore.nix",
-        "rev": "9e21c80adf67ebcb077d75bd5e7d724d21eeafd6",
+        "rev": "a20de23b925fd8264fd7fad6454652e142fd7f73",
         "type": "github"
       },
       "original": {
@@ -266,11 +266,11 @@
         ]
       },
       "locked": {
-        "lastModified": 1700553346,
-        "narHash": "sha256-kW7uWsCv/lxuA824Ng6EYD9hlVYRyjuFn0xBbYltAeQ=",
+        "lastModified": 1701071203,
+        "narHash": "sha256-lQywA7QU/vzTdZ1apI0PfgCWNyQobXUYghVrR5zuIeM=",
         "owner": "nix-community",
         "repo": "home-manager",
-        "rev": "1aabb0a31b25ad83cfaa37c3fe29053417cd9a0f",
+        "rev": "db1878f013b52ba5e4034db7c1b63e8d04173a86",
         "type": "github"
       },
       "original": {
@@ -309,11 +309,11 @@
         ]
       },
       "locked": {
-        "lastModified": 1700529763,
-        "narHash": "sha256-O3BcD/xmO1BPP87wuntpBiADOH1QEbSS3/A//2HrN74=",
+        "lastModified": 1701220839,
+        "narHash": "sha256-mD8SYyQ47zvHcHWe2TfPgSDZhrh+rd7o1Qxc012ikaQ=",
         "owner": "Infinidoge",
         "repo": "nix-minecraft",
-        "rev": "6e99ae61a7e8271343ab5bad736070cd098aca2b",
+        "rev": "0fa82d954e4f9a2f14b43f9301232447b90184e9",
         "type": "github"
       },
       "original": {
@@ -336,11 +336,11 @@
         ]
       },
       "locked": {
-        "lastModified": 1700616109,
-        "narHash": "sha256-RtcYmcqzS1sWAw4q85YiOxEsPL4yo0EhGJIUatExh1A=",
+        "lastModified": 1701220899,
+        "narHash": "sha256-esWkfkEM5P78BKtVIf5qbgcD3L4CdXpkkWv+LhPr6PE=",
         "owner": "nix-community",
         "repo": "nix-vscode-extensions",
-        "rev": "744feda10f39afb587354bb98d04415662b57236",
+        "rev": "f9d2a701aabc5ce2f109f9154fa26eb8d3d785b3",
         "type": "github"
       },
       "original": {
@@ -352,11 +352,11 @@
     },
     "nixos-hardware": {
       "locked": {
-        "lastModified": 1700559156,
-        "narHash": "sha256-gL4epO/qf+wo30JjC3g+b5Bs8UrpxzkhNBBsUYxpw2g=",
+        "lastModified": 1701250978,
+        "narHash": "sha256-ohu3cz4edjpGxs2qUTgbs0WrnewOX4crnUJNEB6Jox4=",
         "owner": "NixOS",
         "repo": "nixos-hardware",
-        "rev": "c3abafb01cd7045dba522af29b625bd1e170c2fb",
+        "rev": "8772491ed75f150f02552c60694e1beff9f46013",
         "type": "github"
       },
       "original": {
@@ -368,11 +368,11 @@
     },
     "nixpkgs": {
       "locked": {
-        "lastModified": 1700538105,
-        "narHash": "sha256-uZhOCmwv8VupEmPZm3erbr9XXmyg7K67Ul3+Rx2XMe0=",
+        "lastModified": 1701174899,
+        "narHash": "sha256-1W+FMe8mWsJKXoBc+QgKmEeRj33kTFnPq7XCjU+bfnA=",
         "owner": "NixOS",
         "repo": "nixpkgs",
-        "rev": "51a01a7e5515b469886c120e38db325c96694c2f",
+        "rev": "010c7296f3b19a58b206fdf7d68d75a5b0a09e9e",
         "type": "github"
       },
       "original": {
@@ -384,11 +384,11 @@
     },
     "nixpkgs-master": {
       "locked": {
-        "lastModified": 1700692803,
-        "narHash": "sha256-ZmLkPHlPWhfRUqlHcX6oDICqiDOWga674DMjyv+k7fM=",
+        "lastModified": 1701282011,
+        "narHash": "sha256-8VA8Dgir7gxye7SGJtnkA0s3CokCDDNsKu8miAbRqT8=",
         "owner": "NixOS",
         "repo": "nixpkgs",
-        "rev": "e4baad1ea299fc9488bc10d0b506389b9ed7c3f2",
+        "rev": "f6a06211e6018028ddaf11fac093ca9b9a13cd7f",
         "type": "github"
       },
       "original": {
@@ -400,11 +400,11 @@
     },
     "nixpkgs-stable": {
       "locked": {
-        "lastModified": 1700682076,
-        "narHash": "sha256-+v5Q0qDioOXNuih+mmiwpyw8vdFy6WG13tzozG5TWxc=",
+        "lastModified": 1701282134,
+        "narHash": "sha256-5Tm7yLcFcBqjjKAm3Asy8TK7jghjZ/eH5++kDEnlCuw=",
         "owner": "NixOS",
         "repo": "nixpkgs",
-        "rev": "ee5ddacfab29812b32b5ea8c1dacdadfdf264475",
+        "rev": "2bc6ba12ff5e3806c41e29aaafd28c6e4fee8a70",
         "type": "github"
       },
       "original": {
@@ -428,11 +428,11 @@
         ]
       },
       "locked": {
-        "lastModified": 1700659845,
-        "narHash": "sha256-nU3fHWd/YKPtnJ+PVqtooVNlFtkSQIfrsq14wyufUXA=",
+        "lastModified": 1701250280,
+        "narHash": "sha256-Nx2nqkUfOAvW+GlVIs5HK8WfuZsbN8FqW2bXNx0fMJc=",
         "owner": "nix-community",
         "repo": "nixvim",
-        "rev": "796e7391cec5134fd36951d275e7a0809e2107c8",
+        "rev": "f56d412f84e2cee53365ade1093f9cc449d58fa3",
         "type": "github"
       },
       "original": {
@@ -520,11 +520,11 @@
         ]
       },
       "locked": {
-        "lastModified": 1700064067,
-        "narHash": "sha256-1ZWNDzhu8UlVCK7+DUN9dVQfiHX1bv6OQP9VxstY/gs=",
+        "lastModified": 1700922917,
+        "narHash": "sha256-ej2fch/T584b5K9sk1UhmZF7W6wEfDHuoUYpFN8dtvM=",
         "owner": "cachix",
         "repo": "pre-commit-hooks.nix",
-        "rev": "e558068cba67b23b4fbc5537173dbb43748a17e8",
+        "rev": "e5ee5c5f3844550c01d2131096c7271cec5e9b78",
         "type": "github"
       },
       "original": {
diff --git a/modules/common/bat.nix b/modules/common/bat.nix
index d95f709..2dc0913 100644
--- a/modules/common/bat.nix
+++ b/modules/common/bat.nix
@@ -13,6 +13,7 @@ in {
       baj = "bat --language=json --tabs 2";
       bay = "bat --language=yaml --tabs 2";
       bas = "bat --language=syslog";
+      less = "bat";
     };
 
     hm.programs.bat = {
diff --git a/modules/common/common/nix.nix b/modules/common/common/nix.nix
index 39e3282..3735174 100644
--- a/modules/common/common/nix.nix
+++ b/modules/common/common/nix.nix
@@ -54,6 +54,8 @@ with lib; {
 
       warn-dirty = false;
 
+      keep-going = true;
+
       substituters = [
         "https://azahi.cachix.org"
         "https://cache.iog.io"
diff --git a/modules/common/default.nix b/modules/common/default.nix
index b360049..3b42031 100644
--- a/modules/common/default.nix
+++ b/modules/common/default.nix
@@ -7,6 +7,7 @@ _: {
     ./curl.nix
     ./direnv.nix
     ./emacs
+    ./eza.nix
     ./fonts.nix
     ./git.nix
     ./gnupg.nix
diff --git a/modules/common/emacs/default.nix b/modules/common/emacs/default.nix
index 94c7729..5402b34 100644
--- a/modules/common/emacs/default.nix
+++ b/modules/common/emacs/default.nix
@@ -66,13 +66,15 @@ in {
                 extraBins = with pkgs;
                   [
                     (aspellWithDicts (p: with p; [en ru])) # :checkers (spell +aspell)
+                    # wordnet # :tools (lookup +dictionary +offline)
                     asmfmt # :editor format
-                    bashdb # :lang sh :tools debugger
                     cargo # :lang rust
                     clang-tools # :lang (cc +lsp) :editor format
                     cmake # :lang cc :term vterm
                     cmake-format # :lang cc :editor format
                     cmigemo # :lang japanese
+                    config.hm.programs.emacs.package # !doom
+                    config.nix.package # !doom
                     dockerfile-language-server-nodejs # :tools (docker +lsp)
                     dockfmt # :tools docker :editor format
                     editorconfig-core-c # :tools editorconfig
@@ -137,7 +139,6 @@ in {
                     texlab # lang (tex +lsp)
                     texlive.combined.scheme-full # :lang org tex
                     unzip # :tools debugger
-                    wordnet # :tools (lookup +dictionary +offline)
                     yaml-language-server # :lang (yaml +lsp)
                     zig # :lang zig :editor format
                     zls # :lang (zig +lsp)
@@ -151,6 +152,11 @@ in {
                     then [gdb] # :tools debugger
                     else [lldb] # :tools debugger
                   );
+
+                parinferRustLibrary =
+                  if (hasSuffix "linux" this.system)
+                  then "${pkgs.parinfer-rust}/lib/libparinfer_rust.so"
+                  else "${pkgs.parinfer-rust}/lib/libparinfer_rust.dylib";
               in ''
                 ;; Integrate packages which are required by various modules
                 ;; without polluting the user's profile.
@@ -181,7 +187,7 @@ in {
 
                 ;; :editor parinfer
                 (setq parinfer-rust-auto-download nil
-                      parinfer-rust-library "${pkgs.parinfer-rust}/lib/libparinfer_rust.so")
+                      parinfer-rust-library "${parinferRustLibrary}")
 
                 ;; :lang nix
                 ;; HACK Trick `nix-mode' to use alejandra instead of nixfmt.
@@ -239,18 +245,7 @@ in {
       programs = {
         emacs = {
           enable = true;
-          package =
-            (pkgs.emacs29.override (finalAttrs: {
-              stdenv = pkgs.useMoldLinker finalAttrs.stdenv;
-            }))
-            .overrideAttrs (_: final: {
-              configureFlags =
-                (final.configureFlags or [])
-                ++ [
-                  "--without-mailutils"
-                  "--without-pop"
-                ];
-            });
+          package = pkgs.emacs29;
         };
 
         bash.initExtra = mkAfter ''
@@ -268,6 +263,10 @@ in {
                   vterm_cmd find-file "$(realpath "''${@:-.}")"
               }
           fi
+
+          # Not sourced from inside Emacs for some reason. Maybe it's not
+          # considered an interactive shell?
+          [[ -f ~/.profile ]] && . ~/.profile
         '';
       };
     };
diff --git a/modules/common/emacs/doom/config.el b/modules/common/emacs/doom/config.el
index dee3d3d..7d92aea 100644
--- a/modules/common/emacs/doom/config.el
+++ b/modules/common/emacs/doom/config.el
@@ -196,8 +196,9 @@
       (mapcar (lambda (server)
                 `(,server
                   :server-buffer-name ,server
-                  :host "shire.net"
-                  :port 6667
+                  :host "azahi.cc"
+                  :port 6697
+                  :tls t
                   :user ,(concat circe-default-user "/" server)
                   :pass ,(lambda (&rest _)
                            (+pass-get-secret "server/soju.manwe.shire.net/azahi"))))
diff --git a/modules/common/eza.nix b/modules/common/eza.nix
new file mode 100644
index 0000000..be590b4
--- /dev/null
+++ b/modules/common/eza.nix
@@ -0,0 +1,21 @@
+{
+  config,
+  lib,
+  pkgs,
+  ...
+}:
+with lib; let
+  cfg = config.nixfiles.modules.eza;
+in {
+  options.nixfiles.modules.eza.enable = mkEnableOption "eza, an alternative to ls";
+
+  config = mkIf cfg.enable {
+    nixfiles.modules.common.shell.aliases = rec {
+      ls = "eza --smart-group --dereference";
+      ll = "${ls} --long --grid";
+      la = "${ll} --header --all";
+    };
+
+    hm.home.packages = [pkgs.eza];
+  };
+}
diff --git a/modules/common/fonts.nix b/modules/common/fonts.nix
index 1e204e5..6bd3e71 100644
--- a/modules/common/fonts.nix
+++ b/modules/common/fonts.nix
@@ -28,8 +28,6 @@ with lib; {
         source-han-sans
         source-han-serif
         noto-fonts
-        noto-fonts-emoji
-        twitter-color-emoji
         font-awesome
       ];
     };
diff --git a/modules/common/profiles/default.nix b/modules/common/profiles/default.nix
index ad5e841..2b24752 100644
--- a/modules/common/profiles/default.nix
+++ b/modules/common/profiles/default.nix
@@ -73,6 +73,8 @@ in {
     ];
 
     nixfiles.modules = {
+      bat.enable = true;
+      eza.enable = true;
       htop.enable = true;
       tmux.enable = true;
       vim.enable = true;
diff --git a/modules/common/profiles/dev/default.nix b/modules/common/profiles/dev/default.nix
index 822778f..2d0c0f6 100644
--- a/modules/common/profiles/dev/default.nix
+++ b/modules/common/profiles/dev/default.nix
@@ -17,7 +17,6 @@ in {
 
   config = mkIf cfg.enable {
     nixfiles.modules = {
-      common.nix.allowedUnfreePackages = ["terraform"];
       bat.enable = true;
       curl.enable = true;
       direnv.enable = true;
@@ -90,8 +89,6 @@ in {
         sops
         httpie
         logcli
-        terraform
-        opentofu
       ];
     };
   };
diff --git a/modules/darwin/profiles/headful.nix b/modules/darwin/profiles/headful.nix
index 01b1951..826e45a 100644
--- a/modules/darwin/profiles/headful.nix
+++ b/modules/darwin/profiles/headful.nix
@@ -10,18 +10,21 @@ in {
   config = mkIf cfg.enable {
     nixfiles.modules.homebrew.enable = true;
 
+    # I'm addicted to GNU...
     hm.home.packages = with pkgs; [
       coreutils
       findutils
+      getopt
       gnugrep
       gnused
       gnutar
+      gzip
+      which
     ];
 
     homebrew.casks = [
       {name = "firefox";}
       {name = "iterm2";}
-      {name = "macfuse";}
       {name = "telegram-desktop";}
     ];
   };
diff --git a/modules/nixos/common/locale.nix b/modules/nixos/common/locale.nix
index 09e0686..9d73af4 100644
--- a/modules/nixos/common/locale.nix
+++ b/modules/nixos/common/locale.nix
@@ -23,6 +23,31 @@ with lib; {
     };
   };
 
+  hm.xdg.configFile."fcitx5/profile".text = generators.toINI {} {
+    "Groups/0" = {
+      Name = "Default";
+      DefaultIM = "mozc";
+      "Default Layout" = "us";
+    };
+
+    "Groups/0/Items/0" = {
+      Name = "keyboard-us";
+      Layout = "";
+    };
+
+    "Groups/0/Items/1" = {
+      Name = "mozc";
+      Layout = "us";
+    };
+
+    "Groups/0/Items/2" = {
+      Name = "keyboard-ru-phonetic";
+      Layout = "";
+    };
+
+    GroupOrder."0" = "Default";
+  };
+
   services.xserver = {
     layout = "us";
     xkbOptions = concatStringsSep "," [
diff --git a/modules/nixos/default.nix b/modules/nixos/default.nix
index 35694f4..ee63ba1 100644
--- a/modules/nixos/default.nix
+++ b/modules/nixos/default.nix
@@ -66,6 +66,7 @@ _: {
     ./unbound.nix
     ./vaultwarden.nix
     ./vim
+    ./wayland.nix
     ./wireguard.nix
     ./x11.nix
     ./xmonad.nix
diff --git a/modules/nixos/dwm.nix b/modules/nixos/dwm.nix
index 459aae5..9c5e283 100644
--- a/modules/nixos/dwm.nix
+++ b/modules/nixos/dwm.nix
@@ -94,28 +94,28 @@ in {
             };
 
             static const Key keys[] = {
-              { MODKEY,           XK_x,      spawn,          {.v = dmenucmd } },
-              { MODKEY,           XK_Return, spawn,          {.v = termcmd } },
-              { MODKEY,           XK_b,      togglebar,      {0} },
-              { MODKEY,           XK_j,      focusstack,     {.i = +1 } },
-              { MODKEY,           XK_k,      focusstack,     {.i = -1 } },
-              { MODKEY|ShiftMask, XK_k,      incnmaster,     {.i = +1 } },
-              { MODKEY|ShiftMask, XK_j,      incnmaster,     {.i = -1 } },
-              { MODKEY,           XK_comma,  setmfact,       {.f = -0.05} },
-              { MODKEY,           XK_period, setmfact,       {.f = +0.05} },
-              { MODKEY,           XK_p,      zoom,           {0} },
-              { MODKEY,           XK_Tab,    view,           {0} },
-              { MODKEY,           XK_d,      killclient,     {0} },
-              { MODKEY,           XK_t,      setlayout,      {.v = &layouts[0]} },
-              { MODKEY,           XK_m,      setlayout,      {.v = &layouts[1]} },
-              { MODKEY,           XK_f,      setlayout,      {.v = &layouts[2]} },
-              { MODKEY,           XK_o,      togglefloating, {0} },
-              { MODKEY,           XK_0,      view,           {.ui = ~0 } },
-              { MODKEY|ShiftMask, XK_0,      tag,            {.ui = ~0 } },
-              { MODKEY,           XK_h,      focusmon,       {.i = -1 } },
-              { MODKEY,           XK_l,      focusmon,       {.i = +1 } },
-              { MODKEY|ShiftMask, XK_h,      tagmon,         {.i = -1 } },
-              { MODKEY|ShiftMask, XK_l,      tagmon,         {.i = +1 } },
+              { MODKEY,           XK_x,      spawn,          {.v = dmenucmd}       },
+              { MODKEY,           XK_Return, spawn,          {.v = termcmd}        },
+              { MODKEY,           XK_b,      togglebar,      {0}                   },
+              { MODKEY,           XK_j,      focusstack,     {.i = +1}             },
+              { MODKEY,           XK_k,      focusstack,     {.i = -1}             },
+              { MODKEY|ShiftMask, XK_k,      incnmaster,     {.i = +1}             },
+              { MODKEY|ShiftMask, XK_j,      incnmaster,     {.i = -1}             },
+              { MODKEY,           XK_comma,  setmfact,       {.f = -0.05}          },
+              { MODKEY,           XK_period, setmfact,       {.f = +0.05}          },
+              { MODKEY,           XK_p,      zoom,           {0}                   },
+              { MODKEY,           XK_Tab,    view,           {0}                   },
+              { MODKEY,           XK_d,      killclient,     {0}                   },
+              { MODKEY,           XK_t,      setlayout,      {.v = &layouts[0]}    },
+              { MODKEY,           XK_m,      setlayout,      {.v = &layouts[1]}    },
+              { MODKEY,           XK_f,      setlayout,      {.v = &layouts[2]}    },
+              { MODKEY,           XK_o,      togglefloating, {0}                   },
+              { MODKEY,           XK_0,      view,           {.ui = ~0}            },
+              { MODKEY|ShiftMask, XK_0,      tag,            {.ui = ~0}            },
+              { MODKEY,           XK_h,      focusmon,       {.i = -1}             },
+              { MODKEY,           XK_l,      focusmon,       {.i = +1}             },
+              { MODKEY|ShiftMask, XK_h,      tagmon,         {.i = -1}             },
+              { MODKEY|ShiftMask, XK_l,      tagmon,         {.i = +1}             },
               TAGKEYS(            XK_1,                      0)
               TAGKEYS(            XK_2,                      1)
               TAGKEYS(            XK_3,                      2)
@@ -125,21 +125,21 @@ in {
               TAGKEYS(            XK_7,                      6)
               TAGKEYS(            XK_8,                      7)
               TAGKEYS(            XK_9,                      8)
-              { MODKEY|ShiftMask, XK_q,      quit,           {0} },
+              { MODKEY|ShiftMask, XK_q,      quit,           {0}                   },
             };
 
             static const Button buttons[] = {
-              { ClkLtSymbol,   0,      Button1, setlayout,      {0} },
+              { ClkLtSymbol,   0,      Button1, setlayout,      {0}                },
               { ClkLtSymbol,   0,      Button3, setlayout,      {.v = &layouts[2]} },
-              { ClkWinTitle,   0,      Button2, zoom,           {0} },
-              { ClkStatusText, 0,      Button2, spawn,          {.v = termcmd } },
-              { ClkClientWin,  MODKEY, Button1, movemouse,      {0} },
-              { ClkClientWin,  MODKEY, Button2, togglefloating, {0} },
-              { ClkClientWin,  MODKEY, Button3, resizemouse,    {0} },
-              { ClkTagBar,     0,      Button1, view,           {0} },
-              { ClkTagBar,     0,      Button3, toggleview,     {0} },
-              { ClkTagBar,     MODKEY, Button1, tag,            {0} },
-              { ClkTagBar,     MODKEY, Button3, toggletag,      {0} },
+              { ClkWinTitle,   0,      Button2, zoom,           {0}                },
+              { ClkStatusText, 0,      Button2, spawn,          {.v = termcmd}     },
+              { ClkClientWin,  MODKEY, Button1, movemouse,      {0}                },
+              { ClkClientWin,  MODKEY, Button2, togglefloating, {0}                },
+              { ClkClientWin,  MODKEY, Button3, resizemouse,    {0}                },
+              { ClkTagBar,     0,      Button1, view,           {0}                },
+              { ClkTagBar,     0,      Button3, toggleview,     {0}                },
+              { ClkTagBar,     MODKEY, Button1, tag,            {0}                },
+              { ClkTagBar,     MODKEY, Button3, toggletag,      {0}                },
             };
           '';
         };
diff --git a/modules/nixos/emacs.nix b/modules/nixos/emacs.nix
index c851389..7d2112b 100644
--- a/modules/nixos/emacs.nix
+++ b/modules/nixos/emacs.nix
@@ -7,19 +7,15 @@ with lib; let
   cfg = config.nixfiles.modules.emacs;
 in {
   config = mkIf cfg.enable {
-    nixfiles.modules = {
-      common.xdg.defaultApplications.emacs = [
-        "application/atom+xml"
-        "application/json"
-        "application/rss+xml"
-        "application/schema+json"
-        "application/xhtml+xml"
-        "application/xml"
-        "text/csv"
-        "text/plain"
-      ];
-
-      x11.enable = true;
-    };
+    nixfiles.modules.common.xdg.defaultApplications.emacs = [
+      "application/atom+xml"
+      "application/json"
+      "application/rss+xml"
+      "application/schema+json"
+      "application/xhtml+xml"
+      "application/xml"
+      "text/csv"
+      "text/plain"
+    ];
   };
 }
diff --git a/modules/nixos/firefox/addons.nix b/modules/nixos/firefox/addons.nix
index fc4d51b..544b5cd 100644
--- a/modules/nixos/firefox/addons.nix
+++ b/modules/nixos/firefox/addons.nix
@@ -892,10 +892,10 @@
   };
   "rikaichamp" = buildFirefoxXpiAddon {
     pname = "rikaichamp";
-    version = "1.15.1";
+    version = "1.16.0";
     addonId = "{59812185-ea92-4cca-8ab7-cfcacee81281}";
-    url = "https://addons.mozilla.org/firefox/downloads/file/4162143/10ten_ja_reader-1.15.1.xpi";
-    sha256 = "cf638be78da479ccd54fe6ace7990a5ba7757562ec48b2a177e24c86d2ee235c";
+    url = "https://addons.mozilla.org/firefox/downloads/file/4200662/10ten_ja_reader-1.16.0.xpi";
+    sha256 = "ac91a5aee5c6a018c397257eb090eaa640feb0a17aa2e0f91248bad7d1a3e6c1";
     meta = with lib; {
       homepage = "https://github.com/birchill/10ten-ja-reader/";
       description = "Quickly translate Japanese by hovering over words. Formerly released as Rikaichamp.";
diff --git a/modules/nixos/fonts.nix b/modules/nixos/fonts.nix
index f9624ec..a333cb3 100644
--- a/modules/nixos/fonts.nix
+++ b/modules/nixos/fonts.nix
@@ -12,7 +12,13 @@ in {
       nixfiles.modules.common.nix.allowedUnfreePackages = ["symbola"];
       hm.fonts.fontconfig.enable = true;
       fonts = {
-        packages = cfg.packages ++ [pkgs.symbola];
+        packages =
+          cfg.packages
+          ++ (with pkgs; [
+            noto-fonts-emoji
+            twitter-color-emoji
+            symbola
+          ]);
 
         fontconfig = {
           enable = true;
diff --git a/modules/nixos/kde.nix b/modules/nixos/kde.nix
index 1a02d9d..adec490 100644
--- a/modules/nixos/kde.nix
+++ b/modules/nixos/kde.nix
@@ -15,7 +15,6 @@ in {
 
       gnupg.pinentry = "qt";
       sound.enable = true;
-      x11.enable = true;
     };
 
     hm = {
diff --git a/modules/nixos/loki.nix b/modules/nixos/loki.nix
index 0a92fbd..6794ba9 100644
--- a/modules/nixos/loki.nix
+++ b/modules/nixos/loki.nix
@@ -87,10 +87,6 @@ in {
           retention_period = "720h";
         };
 
-        cache_config = {
-          enable_fifocache = false;
-        };
-
         schema_config.configs = [
           {
             from = "2020-01-01";
diff --git a/modules/nixos/profiles/headful.nix b/modules/nixos/profiles/headful.nix
index 938b711..a168d0a 100644
--- a/modules/nixos/profiles/headful.nix
+++ b/modules/nixos/profiles/headful.nix
@@ -19,6 +19,9 @@ in {
       dwm.enable = mkDefault false;
       kde.enable = mkDefault true;
       xmonad.enable = mkDefault false;
+
+      # Potentially remove in favor of Wayland in the future.
+      x11.enable = mkDefault true;
     };
 
     hm = {
diff --git a/modules/nixos/soju.nix b/modules/nixos/soju.nix
index b43fbdc..ea95bb3 100644
--- a/modules/nixos/soju.nix
+++ b/modules/nixos/soju.nix
@@ -11,12 +11,6 @@ in {
   options.nixfiles.modules.soju = {
     enable = mkEnableOption "soju";
 
-    protocol = mkOption {
-      description = "Port.";
-      type = with types; enum ["ircs" "irc+insecure"];
-      default = "irc+insecure";
-    };
-
     address = mkOption {
       description = "Address.";
       type = with types; str;
@@ -26,7 +20,7 @@ in {
     port = mkOption {
       description = "Port.";
       type = with types; port;
-      default = 6667;
+      default = 6697;
     };
 
     domain = mkOption {
@@ -50,13 +44,17 @@ in {
     db = "soju";
   in
     mkIf cfg.enable {
-      nixfiles.modules.postgresql = {
-        enable = true;
-        extraPostStart = [
-          ''
-            $PSQL "${db}" -tAc 'GRANT ALL ON SCHEMA "public" TO "${db}"'
-          ''
-        ];
+      nixfiles.modules = {
+        acme.enable = true;
+        nginx.enable = true;
+        postgresql = {
+          enable = true;
+          extraPostStart = [
+            ''
+              $PSQL "${db}" -tAc 'GRANT ALL ON SCHEMA "public" TO "${db}"'
+            ''
+          ];
+        };
       };
 
       services.postgresql = {
@@ -77,7 +75,8 @@ in {
           ExecStart = let
             # https://soju.im/doc/soju.1.html
             configFile = pkgs.writeText "soju.conf" ''
-              listen ${cfg.protocol}://${cfg.address}:${toString cfg.port}
+              listen ircs://${cfg.address}:${toString cfg.port}
+              tls ${with config.certs.${cfg.domain}; "${directory}/fullchain.pem ${directory}/key.pem"}
               ${
                 with cfg.prometheus;
                   optionalString enable
@@ -100,6 +99,7 @@ in {
               "-config ${configFile}"
             ];
           DynamicUser = true;
+          SupplementaryGroups = [config.services.nginx.group];
           AmbientCapabilities = [""];
           CapabilityBoundingSet = [""];
           UMask = "0077";
diff --git a/modules/nixos/syncthing.nix b/modules/nixos/syncthing.nix
index 39579f8..ecc983f 100644
--- a/modules/nixos/syncthing.nix
+++ b/modules/nixos/syncthing.nix
@@ -12,6 +12,12 @@ in {
   options.nixfiles.modules.syncthing = {
     enable = mkEnableOption "Syncthing";
 
+    port = mkOption {
+      description = "Port.";
+      type = with types; port;
+      default = 8384;
+    };
+
     domain = mkOption {
       description = "Domain name sans protocol scheme.";
       type = with types; str;
@@ -41,15 +47,16 @@ in {
         user = my.username;
         inherit (config.my) group;
 
-        dataDir = config.my.home;
+        dataDir = "${config.dirs.config}/syncthing";
+        configDir = config.services.syncthing.dataDir;
 
-        guiAddress = "127.0.0.1:8384";
+        guiAddress = "127.0.0.1:${toString cfg.port}";
 
         cert = config.secrets."syncthing-cert-${this.hostname}".path;
         key = config.secrets."syncthing-key-${this.hostname}".path;
 
-        overrideDevices = true;
-        overrideFolders = true;
+        overrideDevices = false;
+        overrideFolders = false;
 
         settings = {
           options = {
@@ -70,8 +77,11 @@ in {
           devices = mapAttrs (name: attr:
             mkIf (attr.syncthing.id != null && hasAttr "wireguard" attr) {
               inherit (attr.syncthing) id;
-              addresses = ["tcp://${name}.${config.networking.domain}:22000"];
-              introducer = this.isHeadless;
+              compression = "metadata";
+              introducer = false;
+              address = "tcp://${name}.${config.networking.domain}:22000";
+              autoAcceptFolders = true;
+              untrusted = false;
             })
           my.configurations;
 
@@ -107,17 +117,17 @@ in {
                 versioning = trashcan;
               };
               org = {
-                path = "${documents}/org"; # Configured by Emacs.
+                path = "${documents}/org";
                 devices = all;
                 versioning = simple;
               };
               roam = {
-                path = "${documents}/roam"; # Configured by Emacs.
+                path = "${documents}/roam";
                 devices = notOther;
                 versioning = simple;
               };
               elfeed = {
-                path = "${config.my.home}/.elfeed"; # Configured by Emacs.
+                path = "${config.my.home}/.elfeed";
                 devices = notOther;
                 versioning = trashcan;
               };
diff --git a/modules/nixos/wayland.nix b/modules/nixos/wayland.nix
new file mode 100644
index 0000000..5068c25
--- /dev/null
+++ b/modules/nixos/wayland.nix
@@ -0,0 +1,19 @@
+{
+  config,
+  lib,
+  ...
+}:
+with lib; let
+  cfg = config.nixfiles.modules.wayland;
+in {
+  options.nixfiles.modules.wayland.enable = mkEnableOption "Wayland";
+
+  config = mkIf cfg.enable {
+    assertions = [
+      {
+        assertion = !config.nixfiles.modules.x11.enable;
+        message = "Pick only one!";
+      }
+    ];
+  };
+}
diff --git a/modules/nixos/x11.nix b/modules/nixos/x11.nix
index b1bca8f..b629aeb 100644
--- a/modules/nixos/x11.nix
+++ b/modules/nixos/x11.nix
@@ -10,7 +10,12 @@ in {
   options.nixfiles.modules.x11.enable = mkEnableOption "X11";
 
   config = mkIf cfg.enable {
-    nixfiles.modules.fonts.enable = true;
+    assertions = [
+      {
+        assertion = !config.nixfiles.modules.wayland.enable;
+        message = "Pick only one!";
+      }
+    ];
 
     hm = {
       home.sessionVariables = {
diff --git a/nixosConfigurations/eonwe/default.nix b/nixosConfigurations/eonwe/default.nix
index 97ff5e5..a469fff 100644
--- a/nixosConfigurations/eonwe/default.nix
+++ b/nixosConfigurations/eonwe/default.nix
@@ -86,7 +86,6 @@ with lib; {
   # parallelisation support enabled, so we will make sure that all cores are
   # utilised and limit the job queue to one.
   nix.settings = {
-    keep-going = true;
     max-jobs = 1;
     cores = 32;
   };
diff --git a/nixosConfigurations/manwe/default.nix b/nixosConfigurations/manwe/default.nix
index c2ac8be..d9ec359 100644
--- a/nixosConfigurations/manwe/default.nix
+++ b/nixosConfigurations/manwe/default.nix
@@ -47,35 +47,6 @@ with lib; {
     plausible.enable = true;
   };
 
-  # A VPN to play old LAN games with the boys.
-  # secrets."wireguard-private-key-70".file = "${inputs.self}/secrets/wireguard-private-key-70";
-  # networking = mkIf config.nixfiles.modules.wireguard.server.enable {
-  #   wireguard.interfaces.wg70 = {
-  #     ips = ["10.70.0.1/16"];
-  #     listenPort = 7070;
-  #     privateKeyFile = config.secrets."wireguard-private-key-70".path;
-  #     peers = [
-  #       {
-  #         publicKey = "@PUBLIC_KEY@";
-  #         allowedIPs = ["10.70.1.1/32"];
-  #       }
-  #       {
-  #         publicKey = "@PUBLIC_KEY@";
-  #         allowedIPs = ["10.70.1.2/32"];
-  #       }
-  #       {
-  #         publicKey = "@PUBLIC_KEY@";
-  #         allowedIPs = ["10.70.1.3/32"];
-  #       }
-  #       {
-  #         publicKey = "@PUBLIC_KEY@";
-  #         allowedIPs = ["10.70.1.4/32"];
-  #       }
-  #     ];
-  #   };
-  #   firewall.allowedUDPPorts = [7070];
-  # };
-
   boot = {
     loader.grub = {
       enable = true;
diff --git a/packages/nixfiles.nix b/packages/nixfiles.nix
index 02e89f2..bfc869a 100644
--- a/packages/nixfiles.nix
+++ b/packages/nixfiles.nix
@@ -26,6 +26,12 @@
     # Hopefully Naïm will not sue me for copyright infrigment.
     text = ''
       nixfiles="''${NIXFILES:-.}"
+      rebuild="nixos-rebuild"
+      rebuild_opts=(--fast --use-remote-sudo)
+      if [[ "$(uname)" == Darwin ]]; then
+          rebuild="darwin-rebuild"
+          rebuild_opts=()
+      fi
       cmd=$1
       shift
       case $cmd in
@@ -108,10 +114,10 @@
               # Assumes that hosts are configured in the OpenSSH configuration.
               host=''${cmd#@}
               hostname=$(ssh -q "$host" 'echo "$HOSTNAME"')
-              exec nixos-rebuild -v --flake "$nixfiles#$hostname" --target-host "$host" --use-remote-sudo --show-trace "$@"
+              exec "$rebuild" -v --flake "$nixfiles#$hostname" --target-host "$host" "''${rebuild_opts[@]}" --show-trace "$@"
               ;;
           *)
-              exec nixos-rebuild -v --fast --flake "$nixfiles" --use-remote-sudo --show-trace "$cmd" "$@"
+              exec "$rebuild" -v --flake "$nixfiles" "''${rebuild_opts[@]}" --show-trace "$cmd" "$@"
               ;;
       esac
     '';

Consider giving Nix/NixOS a try! <3