====== Cups ======
===== Beállítások biztonsági mentése =====
launchctl unload /System/Library/LaunchDaemons/org.cups.cupsd.plist
tar cvzf cups-backup.tar.gz /etc/cups
launchctl load /System/Library/LaunchDaemons/org.cups.cupsd.plist
===== Szünetelő nyomtatók automatikus engedélyezése =====
* http://www.splinter.com.au/using-launchd-to-run-a-script-every-5-mins-on/
- Hozzuk létre a nyomtató helyreállító ''/opt/tia/tia-enable-printers'' scriptet:
#!/bin/bash -e
PATH=/opt/local/bin:/opt/local/sbin:/opt/local/bin:/opt/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin
lpstat -p |
grep -i disabled |
sed -E 's>^printer ([^ ]+) .*>\1>' |
while read printer
do
cupsaccept "${printer}"
cupsenable "${printer}"
done
exit 0
- Hozzuk létre az ''/opt/tia/tia.enable-printers.plist'' ütemezett feladatot:
Label
tia.enable-printers
ProgramArguments
/opt/tia/tia-enable-printers
StartInterval
15
- Mozgassuk a helyére:
mv '/opt/tia/tia.enable-printers.plist' '/Library/LaunchDaemons/'
- Töltsük be az ütemezett feladatot:
launchctl load -w '/Library/LaunchDaemons/tia.enable-printers.plist'
===== Bug =====
* https://bugs.launchpad.net/ubuntu/+source/cupsys/+bug/255161/comments/28