add printing and libreoffice

This commit is contained in:
Vinzenz Schroeter 2023-10-22 14:14:39 +02:00
parent a488df8854
commit 5cd119f65e
4 changed files with 32 additions and 3 deletions

View file

@ -12,6 +12,7 @@ in {
./gnome.nix
./kde.nix
./gaming.nix
./printing.nix
]
++ lib.optionals isHomeManager [
./gnome-home.nix
@ -22,9 +23,6 @@ in {
config = lib.mkIf isEnabled {
services = {
# Enable CUPS to print documents.
printing.enable = true;
xserver = {
# Enable the X11 windowing system / wayland depending on DE
enable = true;
@ -86,6 +84,12 @@ in {
environment = {
systemPackages = with pkgs; [
lm_sensors
# office
libreoffice-qt
hunspell
hunspellDicts.de-de
hunspellDicts.en-us-large
];
};

View file

@ -0,0 +1,23 @@
{
config,
pkgs,
lib,
...
}: let
isEnabled = config.my.desktop.enablePrinting;
in {
options.my.desktop.enablePrinting = lib.mkEnableOption "printing";
config = lib.mkIf isEnabled {
services = {
# Enable CUPS to print documents.
printing.enable = true;
avahi = {
enable = true; # runs the Avahi daemon
nssmdns = true; # enables the mDNS NSS plug-in
openFirewall = true; # opens the firewall for UDP port 5353
};
};
};
}

View file

@ -12,6 +12,7 @@
desktop = {
enableGnome = true;
enableGaming = true;
enablePrinting = true;
};
};

View file

@ -12,6 +12,7 @@
desktop = {
enableKde = true;
enableGaming = true;
enablePrinting = true;
};
};