~fnux/monitor-handler

ref: a85cadaa9df3162e5fc4496801a2fcb024f57010 monitor-handler/README -rw-r--r-- 767 bytes View raw
a85cadaa — Timothée Floure Initial commit: event listener and simple handler 1 year, 8 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
# monitor-handler

I have access (home, work, club room, ...) to various external screen and often
plug/unplug them to my laptop. Since I don't use a full
[Desktop Environment](https://en.wikipedia.org/wiki/Desktop_environment), their configuration is
not automagically handled whatever us shipped with Gnome, KDE or similar nice
but bloated DE. I figured it would not be to difficult to write a few scripts
to handle it myself:

  * `monitor-event-listener`: simple C program listening for X event. It calls
    `monitor-event-handler` with the output name and action (plugged or unplugged)
    when a "monitor event" is detected.
  * monitor-event-handler: simple shell script taking the output name and
    action as arguments and executing preconfigured actions.