about summary refs log tree commit diff
path: root/home/modules/firefox.nix
diff options
context:
space:
mode:
authorGriffin Smith <root@gws.fyi>2020-03-31T21·10-0400
committerGriffin Smith <root@gws.fyi>2020-03-31T21·10-0400
commit562100bad219434920f1787187c7a3be19c19c86 (patch)
treebafd22d8bf7ae16aab96db8cdde3f28b35e26715 /home/modules/firefox.nix
parentcf4159a6da75200d9e3971cc3253a62cb517ed72 (diff)
More robust config for default firefox browser
Diffstat (limited to 'home/modules/firefox.nix')
-rw-r--r--home/modules/firefox.nix22
1 files changed, 22 insertions, 0 deletions
diff --git a/home/modules/firefox.nix b/home/modules/firefox.nix
new file mode 100644
index 000000000000..c7e78685a5a3
--- /dev/null
+++ b/home/modules/firefox.nix
@@ -0,0 +1,22 @@
+{ config, lib, pkgs, ... }:
+
+{
+
+  xdg.mimeApps = rec {
+    enable = true;
+    defaultApplications = {
+      "text/html" = [ "firefox.desktop" ];
+      "x-scheme-handler/http" = [ "firefox.desktop" ];
+      "x-scheme-handler/https" = [ "firefox.desktop" ];
+      "x-scheme-handler/ftp" = [ "firefox.desktop" ];
+      "x-scheme-handler/chrome" = [ "firefox.desktop" ];
+      "application/x-extension-htm" = [ "firefox.desktop" ];
+      "application/x-extension-html" = [ "firefox.desktop" ];
+      "application/x-extension-shtml" = [ "firefox.desktop" ];
+      "application/xhtml+xml" = [ "firefox.desktop" ];
+      "application/x-extension-xhtml" = [ "firefox.desktop" ];
+      "application/x-extension-xht" = [ "firefox.desktop" ];
+    };
+    associations.added = defaultApplications;
+  };
+}