autorandr detects the connected display hardware and load the appropriate X11 setup by using xrandr. It automatically selects a display configuration based on connected devices.
xrandr