Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question: should autorandr systemd service change profile when external monitor is unplugged? #360

Open
carlotm opened this issue Sep 8, 2023 · 2 comments

Comments

@carlotm
Copy link

carlotm commented Sep 8, 2023

I can't make autorandr to change the profile when the external monitor is unplugged.

Is it supposed to work?
How can I debug what's going on?

Cheers

@phillipberndt
Copy link
Owner

The systemd unit isn't a service, it's started ad hoc as needed. What mechanism do you use to detect changes? udev? Generally, unplug should trigger autorandr.

@carlotm
Copy link
Author

carlotm commented Sep 9, 2023

I am using this udev rule:

$ cat /etc/udev/rules.d/95-monitors.rules
ACTION=="change", SUBSYSTEM=="drm", ENV{DISPLAY}=":0", ENV{XAUTHORITY}="/home/carloratm/.Xauthority", RUN+="/usr/bin/autorandr --change"

It is working when I plug a monitor, does not work when I unplug it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants