LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices

Reply
 
Search this Thread
Old 09-25-2009, 10:35 PM   #1
TeenyLemon
LQ Newbie
 
Registered: Dec 2008
Posts: 27

Rep: Reputation: 16
Question Autostart.sh?


Hey all. I recently decided to try something new and installed Openbox . But i have a problem >__<
I have install pypanel.
And i have put a background image on using:
Code:
feh --bg-scale 2008266122028-11402.jpg
So to keep them up i made an autostart.sh file in ~, but when I fire up linux, neither the background or pypanel appear.
Can anyone help?

Debain Etch (4.0)

And heres my script:
Code:
#!/bin/sh
eval `cat $HOME/.fehbg` &
pypanel &
if pgrep pypanel
then exec openbox
else pypanel && exec openbox
fi
Cheers

Last edited by TeenyLemon; 09-25-2009 at 10:37 PM. Reason: Missed an important detail.
 
Old 09-26-2009, 04:30 AM   #2
antegallya
Member
 
Registered: Jun 2008
Location: Belgium
Distribution: Debian
Posts: 109

Rep: Reputation: 42
Hello,
isn't that file supposed to go in ~/.config/openbox/ instead of ~ ?
autostart.sh will only run if you start openbox as a session, that is with openbox-session.
Moreover, that file is started by openbox before it starts (i.e when autostart.sh returns), thus there's no need to start openbox in it.
 
Old 09-26-2009, 05:22 AM   #3
TeenyLemon
LQ Newbie
 
Registered: Dec 2008
Posts: 27

Original Poster
Rep: Reputation: 16
Wow.
Stupid mistake.
BUT!
I just tried that and it still doesn't work....
Is there something im missing?
 
Old 09-26-2009, 05:27 AM   #4
antegallya
Member
 
Registered: Jun 2008
Location: Belgium
Distribution: Debian
Posts: 109

Rep: Reputation: 42
Try putting something like
Code:
echo "Test" > /home/your_user/OPENBOX
in your autostart.sh and restart openbox. It should tell if the autostart.sh is really run.
 
Old 09-26-2009, 06:19 AM   #5
TeenyLemon
LQ Newbie
 
Registered: Dec 2008
Posts: 27

Original Poster
Rep: Reputation: 16
Okay, I've tried that but it didn't do anything..
I have the same problem when i edited the menu.xml file with obmenu; it hasn't taken affect.
 
Old 09-26-2009, 06:23 AM   #6
antegallya
Member
 
Registered: Jun 2008
Location: Belgium
Distribution: Debian
Posts: 109

Rep: Reputation: 42
Okay then, the autostart.sh is not executed.
How do you start openbox ?
try to manually start X with startx and then start openbox-session.
 
Old 09-27-2009, 02:22 AM   #7
TeenyLemon
LQ Newbie
 
Registered: Dec 2008
Posts: 27

Original Poster
Rep: Reputation: 16
bash displays that "openbox-session" is an unknown command.

I think we may be miss-interpreting where the folder is supposed to be.
Should I try the home folder instead of root?

Last edited by TeenyLemon; 09-27-2009 at 02:24 AM. Reason: spelling mistake
 
Old 09-27-2009, 02:41 AM   #8
antegallya
Member
 
Registered: Jun 2008
Location: Belgium
Distribution: Debian
Posts: 109

Rep: Reputation: 42
Which folder are talking about ?
Anyway, openbox-session shouldn't be an unknown command.
Did you installed openbox from apt or sources ?
The binary should be in /usr/bin/openbox-session.
What does that tell ? :
Code:
dpkg -L openbox | grep openbox-session
If you find it in /usr/bin/openbox-session, try again to start X with startx and then start openbox-session with
Code:
/usr/bin/openbox-session
 
Old 09-28-2009, 12:47 AM   #9
TeenyLemon
LQ Newbie
 
Registered: Dec 2008
Posts: 27

Original Poster
Rep: Reputation: 16
Root... I'm saying maybe i should install it in home folder?

I'm pretty sure i installed it from sources because its not in my Terminal history.

Code:
dpkg -L openbox | grep openbox-session
did not display anything. So i manually checked with cd and there is only an openbox folder not openbox-session.
 
Old 09-28-2009, 12:54 AM   #10
antegallya
Member
 
Registered: Jun 2008
Location: Belgium
Distribution: Debian
Posts: 109

Rep: Reputation: 42
Okay,
since openbox-session is not present for any reason and it is that binary that loads the autostart.sh script, I recommend you to either install it, or use the ~/.Xsession to start your applications.
How do you start openbox ? Do you use an graphical login manager where you select your session or did you specified to launch openbox in your .Xsession ?
 
Old 09-28-2009, 01:10 AM   #11
manwithaplan
Member
 
Registered: Nov 2008
Location: ~/
Distribution: Arch || Sidux
Posts: 393

Rep: Reputation: 45
I personally start "exec openbox-session" from my .xinitrc ... I dont use a displaymanager (kdm.gdm,xdm,slim). This is what my autostart.sh looks like

~/.config/openbox

Code:
# Programs to launch at startup
# =============================
xcompmgr-custom --startstop &

#export OOO_FORCE_DESKTOP=gnome

# Start volume control system tray applet
volwheel &

# Set desktop wallpaper
nitrogen --restore &

# Start screensaver deamon
#gnome-screensaver &

# Launch Conky
conky -q &

# Launch panel
tint2 &

# Numlock
numlockx on &

Last edited by manwithaplan; 09-28-2009 at 01:13 AM.
 
Old 09-29-2009, 01:21 AM   #12
TeenyLemon
LQ Newbie
 
Registered: Dec 2008
Posts: 27

Original Poster
Rep: Reputation: 16
Quote:
Originally Posted by antegallya View Post
Okay,
since openbox-session is not present for any reason and it is that binary that loads the autostart.sh script, I recommend you to either install it, or use the ~/.Xsession to start your applications.
How do you start openbox ? Do you use an graphical login manager where you select your session or did you specified to launch openbox in your .Xsession ?
I usually start openbox through the Debian GUI login screen.
How do i start .Xsession?
God im a major fail. :P

Quote:
I personally start "exec openbox-session" from my .xinitrc ... I dont use a displaymanager (kdm.gdm,xdm,slim). This is what my autostart.sh looks like

~/.config/openbox
Thanks Manwithaplan, I shall try your code and report back later
 
Old 09-29-2009, 02:41 AM   #13
antegallya
Member
 
Registered: Jun 2008
Location: Belgium
Distribution: Debian
Posts: 109

Rep: Reputation: 42
Hello,
I think the default "Debian GUI login screen" is gdm. I haven't used it in a while but it seems that it starts the ~/.xsession only if you choose the "Debian default" entry (or something like that).
Try to put that in your ~/.xsession file and make it executable:
Code:
eval `cat $HOME/.fehbg` &
pypanel &
if pgrep pypanel
then exec openbox
else pypanel && exec openbox
fi
exec openbox
Then try to start the "Debian default" thing in gdm and see if it works.

But again, a better solution would be to get the openbox-session binary, there seems to be something wrong with your installation.
Why don't you install openbox directly from the apt ? Do you really need to compile it from sources ?
 
  


Reply

Tags
etch, openbox, pypanel, sh


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
autostart rfbdrake overproof Linux - Networking 2 04-22-2005 07:14 AM
Kaffine 3.0 autostart festriaqua Linux - Newbie 6 02-28-2005 11:59 AM
autostart noobtesting Mandriva 3 07-04-2004 11:45 AM
Autostart wampfler Fedora 2 01-01-2004 02:18 PM
Autostart Haiyadragon Mandriva 4 12-26-2003 06:35 AM


All times are GMT -5. The time now is 03:03 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration