Skip to content

Commit

Permalink
Launch dock + compositing if on battery
Browse files Browse the repository at this point in the history
  • Loading branch information
windelicato committed May 4, 2014
1 parent b8ae426 commit cc156d2
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions .xinitrc
Expand Up @@ -11,9 +11,15 @@ unclutter -grab -noevents -root &
urxvtd &

if [[ -z `xrandr | grep " connected" | grep 'VGA'` ]]; then
echo "No monitor found"
echo "No monitor found" &
else
xrandr --output VGA1 --auto --above LVDS1
xrandr --output VGA1 --auto --above LVDS1 &
fi

if [[ "`acpi -b | awk '{gsub(/,/,""); print $3}'`" != "Discharging" ]]; then
hsetroot -fill /home/sunn/Pictures/forest-birch.jpg &
compton &
/home/sunn/scripts/docky-launch &
fi

exec $1

0 comments on commit cc156d2

Please sign in to comment.