cups: Add module

This commit is contained in:
PapaTutuWawa committed 2022-04-27 13:10:48 +02:00
1 parent 59f061711a
commit 1361348bf1
4 files changed
+29 -3

No files matched your search

+1
View File
@@ -32,6 +32,7 @@
./services/gamemode
./services/i18n
./services/greetd
./services/cups
# User
#./users/default.nix
+23
View File
@@ -0,0 +1,23 @@
{ lib, config, pkgs, ...}:
let
cfg = config.ptw.services.cups;
in {
options.ptw.services.cups = {
enable = lib.mkEnableOption "Enable Cups";
};
config = lib.mkIf cfg.enable {
environment.systemPackages = with pkgs; [ gnome.simple-scan ];
services.printing = {
enable = true;
drivers = with pkgs; [ hplip ];
};
hardware.sane = {
enable = true;
extraBackends = with pkgs; [ sane-airscan hplip ];
};
};
}
+1 -1
View File
@@ -4,7 +4,7 @@
config = lib.mkIf (config.ptw.system.singleUser == "alexander") {
users.users.alexander = {
isNormalUser = true;
extraGroups = [ "wheel" "audio" "video" "kvm" "input" "libvirtd" ];
extraGroups = [ "wheel" "audio" "video" "kvm" "input" "libvirtd" "scanner" "lp" ];
hashedPassword = "$5$i4aZuQ/WXP.rFOc$lCzDqbrVsqBQt5954O.3bFPknD0jn27MmqzmE4DIAEC";
shell = pkgs.zsh;
useDefaultShell = false;