aboutsummaryrefslogtreecommitdiff
path: root/nixos
diff options
context:
space:
mode:
authorAargh Rai <aargh.rai+git@gmail.com>2025-12-12 13:29:05 +0530
committerAargh Rai <aargh.rai+git@gmail.com>2025-12-12 13:29:05 +0530
commita1522f065e9b3ebc253068e04fbf869e881faf3b (patch)
treebae3d4c01069a7416e3fc1949cf71e9a1be72e1c /nixos
parent42e48b718aa7757819c3c949c23f7fb638a54bdf (diff)
switched from firefox to zen
Diffstat (limited to 'nixos')
-rw-r--r--nixos/apps.nix14
-rw-r--r--nixos/apps/browser.nix35
-rw-r--r--nixos/home.nix1
3 files changed, 39 insertions, 11 deletions
diff --git a/nixos/apps.nix b/nixos/apps.nix
index f23edb8..17fc4a7 100644
--- a/nixos/apps.nix
+++ b/nixos/apps.nix
@@ -1,6 +1,9 @@
{ config, pkgs, ... }:
{
- # $ nix search wget
+ imports =
+ [
+ ./apps/browser.nix
+ ];
environment.systemPackages = with pkgs; [
gimp
vscode
@@ -16,15 +19,6 @@
vlc
];
- xdg = {
- mime.enable = true;
- mime.defaultApplications = {
- # don't use libreoffice draw for pdfs, use firefox
- "application/pdf" = [ "firefox.desktop" ];
- };
- };
-
- # for Localsend
networking.firewall.allowedTCPPorts = [ 53317 8081 ];
networking.firewall.allowedUDPPorts = [ 53317 8081 ];
}
diff --git a/nixos/apps/browser.nix b/nixos/apps/browser.nix
new file mode 100644
index 0000000..5b6ea42
--- /dev/null
+++ b/nixos/apps/browser.nix
@@ -0,0 +1,35 @@
+{ config, inputs, system, ... }:
+{
+ environment.systemPackages = [
+ inputs.zen-browser.packages."${system}".default
+ ];
+ xdg.mime = let
+ value = let
+ zen-browser = inputs.zen-browser.packages.${system}.default;
+ in
+ zen-browser.meta.desktopFileName;
+
+ associations = builtins.listToAttrs (map (name: {
+ inherit name value;
+ }) [
+ "application/x-extension-shtml"
+ "application/x-extension-xhtml"
+ "application/x-extension-html"
+ "application/x-extension-xht"
+ "application/x-extension-htm"
+ "x-scheme-handler/unknown"
+ "x-scheme-handler/mailto"
+ "x-scheme-handler/chrome"
+ "x-scheme-handler/about"
+ "x-scheme-handler/https"
+ "x-scheme-handler/http"
+ "application/xhtml+xml"
+ "application/json"
+ "application/pdf"
+ "text/plain"
+ "text/html"
+ ]);
+ in {
+ defaultApplications = associations;
+ };
+}
diff --git a/nixos/home.nix b/nixos/home.nix
index 23b4ca1..c863ce7 100644
--- a/nixos/home.nix
+++ b/nixos/home.nix
@@ -67,7 +67,6 @@ set ANDROID_NDK_ROOT /opt/android-ndk
set ANDROID_HOME /opt/android-sdk
'';
};
- programs.firefox.enable = true;
environment.systemPackages = with pkgs; [
home-manager
];