2017-08-02 09:49:27 +00:00
|
|
|
{ config, pkgs, ... }:
|
2015-12-04 21:42:44 +00:00
|
|
|
|
2017-08-02 09:49:27 +00:00
|
|
|
let
|
|
|
|
mainUser = config.krebs.build.user.name;
|
|
|
|
in {
|
2015-12-04 21:42:44 +00:00
|
|
|
services.printing = {
|
|
|
|
enable = true;
|
2018-10-08 18:31:31 +00:00
|
|
|
drivers = with pkgs; [
|
2019-01-22 07:15:33 +00:00
|
|
|
# samsungUnifiedLinuxDriver
|
|
|
|
splix # scx 3200
|
2018-10-08 18:31:31 +00:00
|
|
|
cups-dymo # dymo labelwriter
|
|
|
|
foo2zjs # magicolor 1690mf
|
|
|
|
cups-zj-58
|
2022-06-06 19:23:04 +00:00
|
|
|
cups-ptouch
|
2015-12-04 21:42:44 +00:00
|
|
|
];
|
|
|
|
};
|
2016-02-11 16:06:50 +00:00
|
|
|
|
2017-09-11 21:02:58 +00:00
|
|
|
users.users."${mainUser}".extraGroups = [ "scanner" "lp" ];
|
2017-08-02 09:49:27 +00:00
|
|
|
|
2021-03-12 19:29:23 +00:00
|
|
|
# scanners are printers just in reverse anyway
|
|
|
|
services.saned.enable = true;
|
2017-08-02 09:49:27 +00:00
|
|
|
hardware.sane = {
|
|
|
|
enable = true;
|
2017-09-11 21:02:58 +00:00
|
|
|
extraBackends = [ ];
|
2021-05-15 11:17:09 +00:00
|
|
|
extraConfig.xerox_mfp = ''
|
|
|
|
usb 0x04e8 0x3441
|
|
|
|
'';
|
|
|
|
#netConf =
|
|
|
|
# # drucker.lan SCX-3205W
|
|
|
|
# ''
|
|
|
|
# 192.168.111.16''
|
|
|
|
# # uhrenkind.shack magicolor 1690mf
|
|
|
|
#+ ''
|
|
|
|
# 10.42.20.30'';
|
2017-08-02 09:49:27 +00:00
|
|
|
|
2021-05-15 11:17:09 +00:00
|
|
|
## $ scanimage -p --format=jpg --mode=Gray --source="Automatic Document Feeder" -v --batch="lol%d.jpg" --resolution=150
|
2017-08-02 09:49:27 +00:00
|
|
|
|
2021-05-15 11:17:09 +00:00
|
|
|
## requires 'sane-extra', scan via:
|
|
|
|
#extraConfig."magicolor" = ''
|
|
|
|
# net 10.42.20.30 0x2098
|
|
|
|
#''; # 10.42.20.30: uhrenkind.shack magicolor 1690mf
|
2017-08-02 09:49:27 +00:00
|
|
|
};
|
2019-05-08 11:59:13 +00:00
|
|
|
state = [ "/var/lib/cups" ];
|
2021-05-15 11:17:09 +00:00
|
|
|
services.udev.extraRules = ''
|
|
|
|
ATTRS{idVendor}=="04e8", ATTRS{idProduct}=="3441", ENV{libsane_matched}="yes"
|
|
|
|
'';
|
2015-12-04 21:42:44 +00:00
|
|
|
}
|