diff options
| author | Arpit Chakladar <54011232+arpitchakladar@users.noreply.github.com> | 2025-11-27 23:17:55 +0530 |
|---|---|---|
| committer | Arpit Chakladar <54011232+arpitchakladar@users.noreply.github.com> | 2025-11-27 23:17:55 +0530 |
| commit | 547bf872cbf85f4718576e1ac3a0eab094ccd26a (patch) | |
| tree | 9645f7ccaa242d8e19839f197684544a2a6dd319 /modules/tools/brave/default.nix | |
| parent | 1b6736d9b114c10a0fa02fdf9d30037fb44a3ff6 (diff) | |
| download | home-manager-config-547bf872cbf85f4718576e1ac3a0eab094ccd26a.tar.gz home-manager-config-547bf872cbf85f4718576e1ac3a0eab094ccd26a.zip | |
Configured brave for for comfortably sized UI.
Showing file previews in nnn.
Diffstat (limited to 'modules/tools/brave/default.nix')
| -rw-r--r-- | modules/tools/brave/default.nix | 22 |
1 files changed, 20 insertions, 2 deletions
diff --git a/modules/tools/brave/default.nix b/modules/tools/brave/default.nix index 93b4b84..3fd5f22 100644 --- a/modules/tools/brave/default.nix +++ b/modules/tools/brave/default.nix @@ -6,8 +6,26 @@ }; config = lib.mkIf config.tools.brave.enable { - home.packages = [ - pkgs.brave + home.packages = with pkgs; [ + # Modify the brave-browser.desktop entry to scale the UI + (brave.overrideAttrs (old: { + postInstall = (old.postInstall or "") + '' + sed -i 's|^Exec=\(.*brave[^\n]*\)|Exec=\1 --force-device-scale-factor=1.2|' \ + $out/share/applications/brave-browser.desktop + ''; + })) ]; + + home.sessionPath = [ + "${config.home.homeDirectory}/.local/bin" + ]; + + home.file.".local/bin/brave" = { + text = '' +#!${pkgs.bash}/bin/bash +exec ${pkgs.brave}/bin/brave --force-device-scale-factor=1.2 "$@" +''; + executable = true; + }; }; } |
