Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(71)

Side by Side Diff: scripts/xdg-utils-common.in

Issue 6881074: Linux: fix a syntax error in the latest version of xdg-utils. Will report it. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/deps/third_party/xdg-utils/
Patch Set: Created 9 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « scripts/xdg-settings ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 1
2 #---------------------------------------------------------------------------- 2 #----------------------------------------------------------------------------
3 # Common utility functions included in all XDG wrapper scripts 3 # Common utility functions included in all XDG wrapper scripts
4 #---------------------------------------------------------------------------- 4 #----------------------------------------------------------------------------
5 5
6 DEBUG() 6 DEBUG()
7 { 7 {
8 [ -z "${XDG_UTILS_DEBUG_LEVEL}" ] && return 0; 8 [ -z "${XDG_UTILS_DEBUG_LEVEL}" ] && return 0;
9 [ ${XDG_UTILS_DEBUG_LEVEL} -lt $1 ] && return 0; 9 [ ${XDG_UTILS_DEBUG_LEVEL} -lt $1 ] && return 0;
10 shift 10 shift
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after
201 elif `dbus-send --print-reply --dest=org.freedesktop.DBus /org/freedesktop/D Bus org.freedesktop.DBus.GetNameOwner string:org.gnome.SessionManager > /dev/nul l 2>&1` ; then DE=gnome; 201 elif `dbus-send --print-reply --dest=org.freedesktop.DBus /org/freedesktop/D Bus org.freedesktop.DBus.GetNameOwner string:org.gnome.SessionManager > /dev/nul l 2>&1` ; then DE=gnome;
202 elif xprop -root _DT_SAVE_MODE 2> /dev/null | grep ' = \"xfce4\"$' >/dev/nul l 2>&1; then DE=xfce; 202 elif xprop -root _DT_SAVE_MODE 2> /dev/null | grep ' = \"xfce4\"$' >/dev/nul l 2>&1; then DE=xfce;
203 elif xprop -root 2> /dev/null | grep -i '^xfce_desktop_window' >/dev/null 2> &1; then DE=xfce 203 elif xprop -root 2> /dev/null | grep -i '^xfce_desktop_window' >/dev/null 2> &1; then DE=xfce
204 fi 204 fi
205 205
206 if [ x"$DE" = x"" ]; then 206 if [ x"$DE" = x"" ]; then
207 # fallback to checking $DESKTOP_SESSION 207 # fallback to checking $DESKTOP_SESSION
208 case "$DESKTOP_SESSION" in 208 case "$DESKTOP_SESSION" in
209 gnome) 209 gnome)
210 DE=gnome; 210 DE=gnome;
211 ;;
211 LXDE) 212 LXDE)
212 DE=lxde; 213 DE=lxde;
213 ;; 214 ;;
214 xfce|xfce4) 215 xfce|xfce4)
215 DE=xfce; 216 DE=xfce;
216 ;; 217 ;;
217 esac 218 esac
218 fi 219 fi
219 220
220 if [ x"$DE" = x"" ]; then 221 if [ x"$DE" = x"" ]; then
(...skipping 21 matching lines...) Expand all
242 { 243 {
243 version=`LC_ALL=C.UTF-8 kde-config --version 2>/dev/null | grep '^KDE'` 244 version=`LC_ALL=C.UTF-8 kde-config --version 2>/dev/null | grep '^KDE'`
244 major=`echo $version | sed 's/KDE.*: \([0-9]\).*/\1/'` 245 major=`echo $version | sed 's/KDE.*: \([0-9]\).*/\1/'`
245 minor=`echo $version | sed 's/KDE.*: [0-9]*\.\([0-9]\).*/\1/'` 246 minor=`echo $version | sed 's/KDE.*: [0-9]*\.\([0-9]\).*/\1/'`
246 release=`echo $version | sed 's/KDE.*: [0-9]*\.[0-9]*\.\([0-9]\).*/\1/'` 247 release=`echo $version | sed 's/KDE.*: [0-9]*\.[0-9]*\.\([0-9]\).*/\1/'`
247 test "$major" -gt 3 && return $1 248 test "$major" -gt 3 && return $1
248 test "$minor" -gt 5 && return $1 249 test "$minor" -gt 5 && return $1
249 test "$release" -gt 4 && return $1 250 test "$release" -gt 4 && return $1
250 return 0 251 return 0
251 } 252 }
OLDNEW
« no previous file with comments | « scripts/xdg-settings ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698