summaryrefslogtreecommitdiffstats
path: root/lass/3modules
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2021-06-10 21:42:06 +0200
committertv <tv@krebsco.de>2021-06-10 21:42:06 +0200
commit0e6e8b7188b4a2aab7ca467cb20514a70ba09011 (patch)
treecfa9ab8a1a83e0dd139255cf7f7b29bf9a37fdf6 /lass/3modules
parent44c4cb6a453f5bc34c870caa6802548c099e9435 (diff)
parent04a081a3be600cc5e74aadd4f0fee899d6987a85 (diff)
Merge remote-tracking branch 'prism/master'
Diffstat (limited to 'lass/3modules')
-rw-r--r--lass/3modules/browsers.nix13
-rw-r--r--lass/3modules/xjail.nix1
2 files changed, 11 insertions, 3 deletions
diff --git a/lass/3modules/browsers.nix b/lass/3modules/browsers.nix
index 0c77d4da8..4171abdb6 100644
--- a/lass/3modules/browsers.nix
+++ b/lass/3modules/browsers.nix
@@ -5,7 +5,9 @@ let
cfg = config.lass.browser;
browserScripts = {
- chromium = "${pkgs.chromium}/bin/chromium";
+ brave = "${pkgs.brave}/bin/brave";
+ chrome = "${pkgs.google-chrome}/bin/chrome";
+ chromium = "${pkgs.ungoogled-chromium}/bin/chromium";
firefox = "${pkgs.firefox.override {
extraNativeMessagingHosts = [ pkgs.tridactyl-native ];
}}/bin/firefox";
@@ -14,8 +16,9 @@ let
browser-select = let
sortedPaths = sort (a: b: a.value.precedence > b.value.precedence)
+ (filter (x: ! x.value.hidden)
(mapAttrsToList (name: value: { inherit name value; })
- cfg.config);
+ cfg.config));
in if (lib.length sortedPaths) > 1 then
pkgs.writeScriptBin "browser-select" ''
BROWSER=$(echo -e "${concatStringsSep "\\n" (map (getAttr "name") sortedPaths)}" | ${pkgs.dmenu}/bin/dmenu)
@@ -48,6 +51,10 @@ in {
type = types.str;
default = config._module.args.name;
};
+ hidden = mkOption {
+ type = types.bool;
+ default = false;
+ };
precedence = mkOption {
type = types.int;
default = 0;
@@ -58,7 +65,7 @@ in {
};
browser = mkOption {
type = types.enum (attrNames browserScripts);
- default = "chromium";
+ default = "brave";
};
groups = mkOption {
type = types.listOf types.str;
diff --git a/lass/3modules/xjail.nix b/lass/3modules/xjail.nix
index 37f90ee1c..526e12db7 100644
--- a/lass/3modules/xjail.nix
+++ b/lass/3modules/xjail.nix
@@ -147,6 +147,7 @@ with import <stockholm/lib>;
useDefaultShell = true;
createHome = true;
extraGroups = cfg.groups;
+ isNormalUser = true;
}
) config.lass.xjail;