]> git.pld-linux.org Git - packages/dbus.git/blob - dbus-xinitrc.sh
up to 1.14.10
[packages/dbus.git] / dbus-xinitrc.sh
1 #! /bin/sh
2
3 [ -x /usr/bin/dbus-launch -a -f /var/run/dbus.pid ] || return
4
5 # Get configuration
6 . /etc/sysconfig/messagebus
7
8 # Taken from rc-scripts
9 is_yes()
10 {
11         # Check value
12         case "$1" in
13           yes|Yes|YES|true|True|TRUE|on|On|ON|Y|y|1)
14                 # true returns zero
15                 return 0
16                 ;;
17           *)
18                 # false returns one
19                 return 1
20                 ;;
21         esac
22 }
23
24 if [ -z "$DBUS_SESSION_BUS_ADDRESS" ] && is_yes "${SESSION_BUS_X_SESSION}"; then
25         eval `dbus-launch --sh-syntax --exit-with-session`
26 fi
27
28 unset -f is_yes
This page took 0.09197 seconds and 3 git commands to generate.