Add zen browser for linux desktop

This commit is contained in:
larstvei 2025-08-24 03:13:06 +02:00
parent 7ef7ac9d95
commit 20a26068e7
4 changed files with 88 additions and 4 deletions

View File

@ -131,6 +131,27 @@
"type": "github"
}
},
"home-manager_2": {
"inputs": {
"nixpkgs": [
"zen-browser",
"nixpkgs"
]
},
"locked": {
"lastModified": 1752603129,
"narHash": "sha256-S+wmHhwNQ5Ru689L2Gu8n1OD6s9eU9n9mD827JNR+kw=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "e8c19a3cec2814c754f031ab3ae7316b64da085b",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "home-manager",
"type": "github"
}
},
"nix-rosetta-builder": {
"inputs": {
"nixos-generators": "nixos-generators",
@ -259,7 +280,8 @@
"emacs-larstvei": "emacs-larstvei",
"home-manager": "home-manager",
"nix-rosetta-builder": "nix-rosetta-builder",
"nixpkgs": "nixpkgs_3"
"nixpkgs": "nixpkgs_3",
"zen-browser": "zen-browser"
}
},
"systems": {
@ -276,6 +298,27 @@
"repo": "default",
"type": "github"
}
},
"zen-browser": {
"inputs": {
"home-manager": "home-manager_2",
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1755922982,
"narHash": "sha256-YMchUKtaIhICzwwiAP/j6G+KaqRA8xSnGV2dfdVXoHw=",
"owner": "0xc000022070",
"repo": "zen-browser-flake",
"rev": "25f56c0f5b813312f38078418b2229ada41c4bcc",
"type": "github"
},
"original": {
"owner": "0xc000022070",
"repo": "zen-browser-flake",
"type": "github"
}
}
},
"root": "root",

View File

@ -17,6 +17,10 @@
url = "github:cpick/nix-rosetta-builder";
inputs.nixpkgs.follows = "nixpkgs";
};
zen-browser = {
url = "github:0xc000022070/zen-browser-flake";
inputs.nixpkgs.follows = "nixpkgs";
};
emacs-larstvei.url = "github:larstvei/emacs-flake";
};
@ -27,6 +31,7 @@
home-manager,
nix-rosetta-builder,
emacs-larstvei,
zen-browser,
...
}:
{
@ -47,7 +52,10 @@
nixosConfigurations.thinkpad = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = { inherit emacs-larstvei; };
specialArgs = {
inherit emacs-larstvei;
inherit zen-browser;
};
modules = [
home-manager.nixosModules.default
./hosts/thinkpad/configuration.nix

26
home/desktop/default.nix Normal file
View File

@ -0,0 +1,26 @@
{ zen-browser, ... }:
{
imports = [
zen-browser.homeModules.beta
];
programs.zen-browser = {
enable = true;
policies = {
DisableAppUpdate = true;
DisableTelemetry = true;
AutofillAddressesEnabled = false;
AutoFillCreditCardEnabled = false;
DisablePocket = true;
DisableProfileImport = true;
DisableSetDesktopBackground = true;
DontCheckDefaultBrowser = true;
HomepageURL = "https://start.hadi.diy";
StartPage = "homepage";
NewTabPage = true;
OfferToSaveLogins = false;
# find more options here: https://mozilla.github.io/policy-templates/
};
};
}

View File

@ -2,6 +2,7 @@
config,
pkgs,
emacs-larstvei,
zen-browser,
...
}:
let
@ -17,8 +18,14 @@ in
home-manager = {
useGlobalPkgs = true;
useUserPackages = true;
extraSpecialArgs = { inherit emacs-larstvei; };
users.${v.username}.imports = [ ../../home ];
extraSpecialArgs = {
inherit emacs-larstvei;
inherit zen-browser;
};
users.${v.username}.imports = [
../../home
../../home/desktop
];
};
users.users.${v.username} = {