[Debian-eeepc-commits] [SCM] Maintenance of eeepc-acpi-scripts debian package branch, master, updated. 1.1.0-beta.1-25-gffd4101
Darren Salt
linux at youmustbejoking.demon.co.uk
Mon Jun 15 22:39:19 UTC 2009
The following commit has been merged in the master branch:
commit ffd41016a47772710beb55bd2e9948a498f35176
Author: Darren Salt <linux at youmustbejoking.demon.co.uk>
Date: Mon Jun 15 23:27:31 2009 +0100
Get the LVDS output no. in the same way as for VGA.
diff --git a/etc/acpi/actions/vga-toggle.sh b/etc/acpi/actions/vga-toggle.sh
index cf34456..ffb0a9b 100755
--- a/etc/acpi/actions/vga-toggle.sh
+++ b/etc/acpi/actions/vga-toggle.sh
@@ -12,12 +12,11 @@ if [ -e "$DEFAULT" ]; then . "$DEFAULT"; fi
# return: 0 on disconnect, 1 on connected vga, 2 else
# set VGA (and LVDS) to the output name, VGA or VGA1 (LVDS or LVDS1)
getvga_status(){
- STATUSLINE=$( xrandr -q | grep VGA)
- STATUS=$( echo $STATUSLINE | cut -d ' ' -f 2,3 )
- VGA=$( echo $STATUSLINE | cut -d ' ' -f 1 )
- # To not call xrandr again
- NUM=${VGA##VGA}
- LVDS=LVDS$NUM
+ STATUSTEXT="$( xrandr -q )"
+ STATUSLINE=$( echo "$STATUSTEXT" | grep ^VGA | head -n1 )
+ STATUS=$( echo "$STATUSLINE" | cut -d ' ' -f 2,3 )
+ VGA=$( echo "$STATUSLINE" | cut -d ' ' -f 1 )
+ LVDS=$( echo "$STATUSTEXT" | grep ^LVDS | head -n1 | cut -d ' ' -f 1 )
case "$STATUS" in
disconnected*)
return 0
--
Maintenance of eeepc-acpi-scripts debian package
More information about the Debian-eeepc-commits
mailing list