about summary refs log tree commit diff
path: root/modules/nixos
diff options
context:
space:
mode:
Diffstat (limited to 'modules/nixos')
-rw-r--r--modules/nixos/beets.nix3
-rw-r--r--modules/nixos/common/nix.nix2
-rw-r--r--modules/nixos/firefox/default.nix1
-rw-r--r--modules/nixos/git/default.nix25
4 files changed, 18 insertions, 13 deletions
diff --git a/modules/nixos/beets.nix b/modules/nixos/beets.nix
index ccceaeb..f01e412 100644
--- a/modules/nixos/beets.nix
+++ b/modules/nixos/beets.nix
@@ -1,6 +1,7 @@
 {
   config,
   lib,
+  pkgs,
   ...
 }:
 with lib; let
@@ -27,6 +28,8 @@ in {
         beets = {
           enable = true;
 
+          package = pkgs.beets-unstable;
+
           settings = {
             library = "${beetsdir}/library.db";
             directory = config.userDirs.music;
diff --git a/modules/nixos/common/nix.nix b/modules/nixos/common/nix.nix
index c0061db..0caf265 100644
--- a/modules/nixos/common/nix.nix
+++ b/modules/nixos/common/nix.nix
@@ -14,6 +14,8 @@ in {
   };
 
   config = {
+    nix.settings.trusted-users = ["@wheel"];
+
     nixpkgs.config.allowUnfreePredicate = p: elem (getName p) cfg.allowedUnfreePackages;
 
     system.stateVersion = with builtins;
diff --git a/modules/nixos/firefox/default.nix b/modules/nixos/firefox/default.nix
index 2e24f23..e725e95 100644
--- a/modules/nixos/firefox/default.nix
+++ b/modules/nixos/firefox/default.nix
@@ -538,6 +538,7 @@ in {
             "browser.search.update" = false;
             "browser.tabs.closeWindowWithLastTab" = true;
             "browser.tabs.firefox-view" = false;
+            "browser.tabs.firefox-view-next" = false;
             "browser.tabs.inTitlebar" = 1;
             "browser.tabs.warnOnClose" = false;
             "browser.tabs.warnOnCloseOtherTabs" = false;
diff --git a/modules/nixos/git/default.nix b/modules/nixos/git/default.nix
index 9fb43db..4268f82 100644
--- a/modules/nixos/git/default.nix
+++ b/modules/nixos/git/default.nix
@@ -73,10 +73,10 @@ in {
             fastcgi_param QUERY_STRING $args;
             fastcgi_param HTTP_HOST $server_name;
 
-            # This makes `go get ...` work and adds analytics.
-            sub_filter '</head>'
-                '<meta name="go-import" content="$host$uri git https://$host$uri"><script defer data-domain="${cfg.server.domain}" src="https://plausible.shire.net/js/script.js"></script></head>';
-            sub_filter_once on;
+            ${nginxAppendHead [
+              ''<meta name="go-import" content="$host$uri git https://$host$uri">''
+              (htmlPlausibleScript {inherit (cfg.server) domain;})
+            ]}
           '';
           "~* ^.+(cgit.css|robots.txt)$".extraConfig = ''
             root ${cfg.server.package}/cgit;
@@ -88,16 +88,15 @@ in {
             alias ${./favicon.ico};
           '';
           "~* ^.+cgit-custom-style.css$".extraConfig = let
-            css = with config.colourScheme;
-              pkgs.writeText "custom.css" ''
-                @import url("cgit.css");
+            css = pkgs.writeText "custom.css" ''
+              @import url("cgit.css");
 
-                div#cgit {
-                  font-family: "${config.fontScheme.monospaceFont.family}", monospace;
-                  -moz-tab-size: 4;
-                  tab-size: 4;
-                }
-              '';
+              div#cgit {
+                font-family: "${config.fontScheme.monospaceFont.family}", monospace;
+                -moz-tab-size: 4;
+                tab-size: 4;
+              }
+            '';
           in ''
             alias ${css};
           '';

Consider giving Nix/NixOS a try! <3