I'm using a Thinkpad W510 and constantly change locations. I'm using disper and auto-disper to change screen profiles (undocked; laptop screen + external screen; two external screens).
I wanted to run auto-disper --change
after waking up, so I put the following script in /etc/pm/sleep.d
:
#!/bin/bash
case "$1" in
thaw | resume )
auto-disper --change &> /home/myHome/autodisper_on_wake.txt
;;
esac
Upon wake, I get the following in autodisper_on_wake.txt
, indicating that the script did fire:
Assuming disper defaults...
'NoneType' object has no attribute 'endswith'
Unable to fingerprint display configuration
home
school
undocked
But no change happened - despite unplugging my monitor before waking my machine (going from profile 'school' to profile 'undocked'), I'm still in profile 'school'.
Any ideas how to proceed? (FWIW, I changed autorandr to have PROFILE and CONFIG point to my absolute home directory, rather than ~ [I thought maybe wake scripts execute as root, so it would look in ~root for profile data]).