#!/bin/bash # Dual-head configuration script with xrandr xrandr --setprovideroutputsource nouveau Intel INTERNAL_OUTPUT="LVDS1" INTERNAL_OUTPUT_BRIGHTNESS=0.75 EXTERNAL_OUTPUT=$(xrandr -q | egrep "^HDMI[0-9-]+ connected" | sed -r "s/^(HDMI[0-9-]+).+$/\1/") INTERNAL_OUTPUT_OFFSET="1366x768" echo "External screen found at $EXTERNAL_OUTPUT." # Positioning the external screen on the left xrandr --output $EXTERNAL_OUTPUT --left-of $INTERNAL_OUTPUT # Switching on the left screen and positionning the right screen xrandr --output $EXTERNAL_OUTPUT --mode 1920x1080 --pos 0x0 --rotate normal xrandr --output $INTERNAL_OUTPUT --pos $INTERNAL_OUTPUT_OFFSET #echo "Redémarrage de Conky..." #killall conky #conky -q & #if [ $? -ne 0 ] #then #echo "Erreur !" #fi