3 Automatically select a display configuration based on connected devices
5 Stefan Tomanek <[stefan.tomanek@wertarbyte.de](stefan.tomanek@wertarbyte.de)>
9 The original wertarbyte/autorandr tree seems unmaintained, with lots of open
10 pull requests and issues. I forked it and merged what I thought were the most
11 important changes. I will maintain this branch until wertarbyte finds the time
12 to maintain his branch again.
17 Save your current display configuration and setup with:
19 autorandr --save mobile
22 Connect an additional display, configure your setup and save it:
24 autorandr --save docked
27 Now autorandr can detect which hardware setup is active:
34 To automatically reload your setup, just append `--change` to the command line
36 To manually load a profile, you can use the `--load <profile>` option.
38 autorandr tries to avoid reloading an identical configuration. To force the
39 (re)configuration, apply `--force`.
41 To prevent a profile from being loaded, place a script call _block_ in its
42 directory. The script is evaluated before the screen setup is inspected, and
43 in case of it returning a value of 0 the profile is skipped. This can be used
44 to query the status of a docking station you are about to leave.
46 If no suitable profile can be identified, the current configuration is kept.
47 To change this behaviour and switch to a fallback configuration, specify
48 `--default <profile>`.
50 Another script called `postswitch` can be placed in the directory
51 `~/.autorandr` as well as in all profile directories: The scripts are executed
52 after a mode switch has taken place and can notify window managers or other
53 applications about it.
55 While the script uses xrandr by default, calling it by the name `autodisper`
56 or `auto-disper` forces it to use the [disper](http://willem.engen.nl/projects/disper/)
57 utility, which is useful for controlling nvidia chipsets. The formats for
58 fingerprinting the current setup and saving/loading the current configuration
59 are adjusted accordingly.
61 To install autorandr call `make install`, define your setup and then call
62 `make hotplug` to install hotplug scripts.
64 For Debian using auto-disper:
65 To make the screen auto-configure when your computer wakes up,
66 * Copy auto-disper into /usr/local/bin/
67 * Copy pm-utils/40auto-disper into /etc/pm/sleep.d/
68 * (Assuming gnome) Run gnome-keybinding-properties and ADD a shortcut,
69 I called it "Run auto-disper", I set it to CTRL-F7, and the command is:
70 `auto-disper -c --default default`
71 * Create a default disper setting... eg for laptop: unplug all monitors,
72 set up the screen nicely on the laptop display.
73 Then run `auto-disper --save laptop`