#!/bin/bash

# There's something wrong with d-bus invocation,
# so we are doing a rather dirty forced-launch
# before the real startactive is run

#pkill -u ${USER} dbus-launch
#pkill -u ${USER} dbus-daemon

#unset DBUS_SESSION_BUS_ADDRESS
#unset DBUS_SESSION_BUS_PID

#export `dbus-launch`
#sleep 3

env > /tmp/startactive-${USER}.env
if [ -f /etc/mer-release ]; then
    ck-launch-session startactive.bin 2>&1 | tee /tmp/startactive-${USER}.log
else
    startactive.bin 2>&1 | tee /tmp/startactive-${USER}.log
fi

