{ lib, config, pkgs, jail, ... }: let cfg = config.l.librewolf; in { options.l.librewolf.enable = lib.mkEnableOption "Enable librewolf"; config = lib.mkIf cfg.enable { home-manager.users.${config.l.home.username} = { home.packages = [ (jail "librewolf" pkgs.librewolf ( combinators: with combinators; [ (add-runtime '' mkdir -p ~/.librewolf mkdir -p ~/.cache/librewolf '') gui network pipewire (readwrite (noescape "~/.librewolf/")) (readwrite (noescape "~/.cache/librewolf/")) (dbus { own = [ "io.gitlab.librewolf.*" ]; talk = [ "org.freedesktop.portal.Desktop" "io.gitlab.librewolf.*" ]; see = [ "io.gitlab.librewolf.*" ]; call = [ ]; broadcast = [ ]; }) gpu #(wrap-entry (entry: '' # export PULSE_SERVER="$XDG_RUNTIME_DIR/pulse/native" # ${entry} #'')) ] )) ]; }; }; }