From 9956b987a2af2c29575d9db8bde6a9eb24c24053 Mon Sep 17 00:00:00 2001 From: Emmet Date: Sat, 30 Sep 2023 21:24:38 -0500 Subject: [PATCH] Makes qutebrowser primary browser wrt to xdg --- user/app/browser/qutebrowser.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/user/app/browser/qutebrowser.nix b/user/app/browser/qutebrowser.nix index fb6ed62..f1c065f 100644 --- a/user/app/browser/qutebrowser.nix +++ b/user/app/browser/qutebrowser.nix @@ -5,6 +5,13 @@ (pkgs.callPackage ./qute-containers.nix { dmenuCmd = "fuzzel -d"; }) ]; home.sessionVariables = { DEFAULT_BROWSER = "${pkgs.qutebrowser}/bin/qutebrowser"; }; + xdg.mimeApps.defaultApplications = { + "text/html" = "org.qutebrowser.qutebrowser.desktop"; + "x-scheme-handler/http" = "org.qutebrowser.qutebrowser.desktop"; + "x-scheme-handler/https" = "org.qutebrowser.qutebrowser.desktop"; + "x-scheme-handler/about" = "org.qutebrowser.qutebrowser.desktop"; + "x-scheme-handler/unknown" = "org.qutebrowser.qutebrowser.desktop"; + }; home.file.".config/qutebrowser/userscripts/container-open".source = "${(pkgs.callPackage ./qute-containers.nix { dmenuCmd = "fuzzel -d"; })}/bin/container-open"; home.file.".config/qutebrowser/userscripts/containers_config".source = "${(pkgs.callPackage ./qute-containers.nix { dmenuCmd = "fuzzel -d"; })}/bin/containers_config";