You are not logged in.

#1 2010-09-07 03:30:03

duke11235
Member
Registered: 2009-10-09
Posts: 221

[SOLVED]Openbox Autostart not Autostarting

So I recently realized that my having openbox on both root and user were conflicting, and deleted the root files. However, now The commands in my autostart.sh fail to execute my startup programs, like conky, feh and tint2

Here is my autostart.sh:

# This shell script is run before Openbox launches.
# Environment variables set here are passed to the Openbox session.

# Set a background color
BG=""
if which hsetroot >/dev/null 2>&1; then
    BG=hsetroot
else
    if which esetroot >/dev/null 2>&1; then
    BG=esetroot
    else
    if which xsetroot >/dev/null 2>&1; then
        BG=xsetroot
    fi
    fi
fi
test -z $BG || $BG -solid "#303030"

# D-bus
if which dbus-launch >/dev/null 2>&1 && test -z "$DBUS_SESSION_BUS_ADDRESS"; then
       eval `dbus-launch --sh-syntax --exit-with-session`
fi

# Make GTK apps look and behave how they were set up in the gnome config tools
#if test -x /usr/libexec/gnome-settings-daemon >/dev/null; then
#  /usr/libexec/gnome-settings-daemon &
#elif which gnome-settings-daemon >/dev/null 2>&1; then
#  gnome-settings-daemon &
# Make GTK apps look and behave how they were set up in the XFCE config tools
#elif which xfce-mcs-manager >/dev/null 2>&1; then
#xfce-mcs-manager n &
fi

# Preload stuff for KDE apps
#if which start_kdeinit >/dev/null 2>&1; then
# LD_BIND_NOW=true start_kdeinit --new-startup +kcminit_startup &
fi

# Run XDG autostart things.  By default don't run anything desktop-specific
# See xdg-autostart --help more info
#DESKTOP_ENV="OPENBOX"
#if which /usr/lib/openbox/xdg-autostart >/dev/null 2>&1; then
#  /usr/lib/openbox/xdg-autostart $DESKTOP_ENV
fi
# Run the system-wide support stuff
. $GLOBALAUTOSTART

# Programs to launch at startup
#hsetroot ~/wallpaper.png &
xcompmgr -c -t-5 -l-5 -r4.2 -o.55 &
sh ~/.fehbg &
xcalib /home/duke/colorprofiles/Color\ LCD-00000610-000004272300.icc &
# SCIM support (for typing non-english characters)
export LC_CTYPE=ja_JP.utf8
export XMODIFIERS=@im=SCIM
export GTK_IM_MODULE=scim
export QT_IM_MODULE=scim
scim -d &

# Programs that will run after Openbox has started
(sleep 2 && tint2) &
~/.scripts/conkystart.sh &
    fi
    fi
fi

Can someone tell me why this is occuring?

Last edited by duke11235 (2010-10-10 17:29:31)

Offline

#2 2010-09-07 04:14:11

munkyeetr
Member
From: Merritt, BC
Registered: 2008-08-07
Posts: 83

Re: [SOLVED]Openbox Autostart not Autostarting

One thing I notice with your autostart.sh is you have commented out quite a few if statements, but left the closing fi uncommented (in several spots). I'm pretty sure that will cause some issues.

Not sure if that will be the source of the problem, but something you may want to clean up.


If the advice you're given in this forum solves your issue, please mark the post as [SOLVED] in consideration to others.

"More than any time in history mankind faces a crossroads. One path leads to despair and utter hopelessness, the other to total extinction.
Let us pray that we have the wisdom to choose correctly." -- Woody Allen

Offline

#3 2010-09-07 09:02:52

ctrl
Member
Registered: 2010-08-30
Posts: 11

Re: [SOLVED]Openbox Autostart not Autostarting

For debugging, you can insert some 'echo "text" >> /home/NAME/file' to see where it breaks...

Offline

#4 2010-09-07 09:50:16

kpbotbot
Member
From: Philippines
Registered: 2010-08-02
Posts: 93
Website

Re: [SOLVED]Openbox Autostart not Autostarting

Bump (first bump in the entire history of me writing in forums). Same problem.


Sex is not the answer.

Sex is the question, and Yes is the answer.

Offline

#5 2010-09-07 10:16:45

bernarcher
Forum Fellow
From: Germany
Registered: 2009-02-17
Posts: 2,273

Re: [SOLVED]Openbox Autostart not Autostarting

ctrl wrote:

For debugging, you can insert some 'echo "text" >> /home/NAME/file' to see where it breaks...

Alas, this works only if the shell file is syntactically correct. Thus, first try to run your autostart.sh from a console to find out what bash complains for.

Last edited by bernarcher (2010-09-07 10:17:06)


To know or not to know ...
... the questions remain forever.

Offline

#6 2010-09-07 10:19:38

kgas
Member
From: Qatar
Registered: 2008-11-08
Posts: 718

Re: [SOLVED]Openbox Autostart not Autostarting

first start with simple tasks in autostart.sh and keep adding. Try all the conditional statements latter.

Offline

#7 2010-09-07 12:35:50

munkyeetr
Member
From: Merritt, BC
Registered: 2008-08-07
Posts: 83

Re: [SOLVED]Openbox Autostart not Autostarting

I don't use openbox currently, but I believe you should still have a fresh copy of autostart.sh in /etc/xdg/openbox to start over with. If not, here is a copy of mine:

# This shell script is run before Openbox launches.
# Environment variables set here are passed to the Openbox session.

#
# DUKE11235...THIS IS WHERE I HAD MY AUTOSTART APPS (tint2, tilda, wicd-client) LISTED :: MUNKY
#

# Set a background color
BG=""
if which hsetroot >/dev/null 2>&1; then
    BG=hsetroot
else
    if which esetroot >/dev/null 2>&1; then
    BG=esetroot
    else
    if which xsetroot >/dev/null 2>&1; then
        BG=xsetroot
    fi
    fi
fi
test -z $BG || $BG -solid "#303030"

# D-bus
if which dbus-launch >/dev/null 2>&1 && test -z "$DBUS_SESSION_BUS_ADDRESS"; then
       eval `dbus-launch --sh-syntax --exit-with-session`
fi

# Make GTK apps look and behave how they were set up in the gnome config tools
if test -x /usr/libexec/gnome-settings-daemon >/dev/null; then
  /usr/libexec/gnome-settings-daemon &
elif which gnome-settings-daemon >/dev/null 2>&1; then
  gnome-settings-daemon &
# Make GTK apps look and behave how they were set up in the XFCE config tools
elif which xfce-mcs-manager >/dev/null 2>&1; then
  xfce-mcs-manager n &
fi

# Preload stuff for KDE apps
if which start_kdeinit >/dev/null 2>&1; then
  LD_BIND_NOW=true start_kdeinit --new-startup +kcminit_startup &
fi

# Run XDG autostart things.  By default don't run anything desktop-specific
# See xdg-autostart --help more info
DESKTOP_ENV="OPENBOX"
if which /usr/lib/openbox/xdg-autostart >/dev/null 2>&1; then
  /usr/lib/openbox/xdg-autostart $DESKTOP_ENV
fi

I hope this is useful,
Munky


If the advice you're given in this forum solves your issue, please mark the post as [SOLVED] in consideration to others.

"More than any time in history mankind faces a crossroads. One path leads to despair and utter hopelessness, the other to total extinction.
Let us pray that we have the wisdom to choose correctly." -- Woody Allen

Offline

#8 2010-09-07 13:06:35

Labello
Member
From: Germany
Registered: 2010-01-21
Posts: 315
Website

Re: [SOLVED]Openbox Autostart not Autostarting

everything looks good except the not so well outcommented if-statements (i. e. fi-statements)...

this should solve it!


"They say just hold onto your hope but you know if you swallow your pride you will choke"
Alexisonfire - Midnight Regulations

Offline

#9 2010-09-08 00:14:39

duke11235
Member
Registered: 2009-10-09
Posts: 221

Re: [SOLVED]Openbox Autostart not Autostarting

I'm sure that fixing the statements helps, but you don't want to comment out most of that document. My problem was deleting the xdg folder in /etc/xdg, and was fixed by reinstalling the openbox package

Offline

Board footer

Powered by FluxBB