systemd unit: Rate limit execution

This prevents the udev rule to run autorandr once per monitor added or
removed, instead of once per change -- this is relevant, e.g., if a
notebook is (dis-)connected to/from a docking station.
This commit is contained in:
Phillip Berndt 2016-11-24 17:40:31 +01:00
parent ae1f18a060
commit 455809c32d
1 changed files with 2 additions and 0 deletions

View File

@ -1,6 +1,8 @@
[Unit]
Description=autorandr execution hook
After=sleep.target
StartLimitInterval=5
StartLimitBurst=1
[Service]
ExecStart=/usr/bin/autorandr --batch --change --default default