Guest SDMF Posted February 18, 2003 Report Share Posted February 18, 2003 I'm trying out fluxbox, and I can get dockapps to run if I run them manually. However, I want to have them start up when I log into fluxbox. I looked at the documentation, and it recommended putting the commands in my .xinitrc script. I put them there, but it still does not load up when I log in. To tell you the truth, I don't really understand .xinitrc. I know its an initialization script for X, but I don't know when it runs. Right now I am using GDM to log in to my different window managers, I don't know if that would impact .xinitrc at all, I kinda doubt it. I just want the dockapps to run as background processes automatically when I log in to fluxbox. Quote Link to comment Share on other sites More sharing options...
beesea Posted February 18, 2003 Report Share Posted February 18, 2003 i believe that .xinitrc only works if you use startx to get into x. if you wanna start dockapps, edit the fluxbox file in /etc/X11/wmsession.d/. after the line that says SCRIPT, add the lines for the dockapps. Quote Link to comment Share on other sites More sharing options...
Guest SDMF Posted February 18, 2003 Report Share Posted February 18, 2003 I'll try that, thanks. I'm quite sure that doing it that way will make the dockapps universal, though, is there a way to do it for an individual user? Quote Link to comment Share on other sites More sharing options...
Guest SDMF Posted February 18, 2003 Report Share Posted February 18, 2003 OK, I got the dockapps to come up on login by putting it in the startfluxbox script. However, they are not appearing in the location specified by my .fluxbox/init file. How can I get them to? Quote Link to comment Share on other sites More sharing options...
Guest SDMF Posted February 18, 2003 Report Share Posted February 18, 2003 Nevermind, figured it out. Quote Link to comment Share on other sites More sharing options...
Guest SDMF Posted February 18, 2003 Report Share Posted February 18, 2003 Still looking to find a way to make the dockapps user-specific if anyone knows. I have the commands in my startfluxbox script right now, but that makes the choices global. Quote Link to comment Share on other sites More sharing options...
bvc Posted February 18, 2003 Report Share Posted February 18, 2003 if your script is in /usr/share/fluxbox or /usr/local/fluxbox it will be global. To make the script user specific it needs to be in /home/user_name/.fluxbox. Flux will look here first for an init and if it finds one will use it. Copy init from /usr/share or /usr/local/share/fluxbox to the /home/user_name/.fluxbox and edit *everything* ini it as necessary. Quote Link to comment Share on other sites More sharing options...
Guest SDMF Posted February 18, 2003 Report Share Posted February 18, 2003 Well, right now I have it in the /usr/bin/startfluxbox script that is called by the entry in /etc/X11/wmsession.d/ It's not in the init file. Are you saying to put it in as an entry in .fluxbox/init in the format session.rootCommand: wmusic & ? I'll give that a try right now, haven't tried that yet. Quote Link to comment Share on other sites More sharing options...
bvc Posted February 18, 2003 Report Share Posted February 18, 2003 I personally have never run a dockapp but yes that should work. What most do is create a script with everything in it like a ~/.xinitrc (can put them there also) called autostart.sh (or anything) then put that as your root command. session.rootCommand: sh ~/.fluxbox/autostart.sh Quote Link to comment Share on other sites More sharing options...
theYinYeti Posted February 18, 2003 Report Share Posted February 18, 2003 Basically, you've got two problems: 1- start applications at startup of window manager 2- start dockapps specifically Here's my solution (I'm currently using Fluxbox): 1- For the first problem, I did not find a ready solution, because, as someone already said, .xinitrc is only read when X is started from the command line. If you use GDM, you can follow my advice: http://www.mandrakeusers.org/viewtopic.php...p?p=11808#11808 It's easy, really. Then you can execute anything you want from the executable .Xclients so that they execute in the background). 2- Now dockapps. The problem is that some won't run if they are started before the window manager. The solution is to write that in the .Xclients( # no & at the end of next line! sleep 15s /path/to/dockapp1 & /path/to/dockapp2 & # and so on... ) &[/code]If 15s is too much time before startup of the dockapps, you can try to shorten it, eg to 10s... I hope this helps. Yves. Quote Link to comment Share on other sites More sharing options...
Guest SDMF Posted February 18, 2003 Report Share Posted February 18, 2003 Well, I added that stuff to the Default script in /etc/X11/gdm/PreSession/, and then created a .Xclients file in my home directory in the format you suggested. However, the dockapps never loaded. I can, once I am logged into fluxbox, execute the script manually, and it will load the dockapps. That kinda defeats the purpose though. I even did a chmod +x on my .Xclients file to see if that was the problem, and it still did not work. I tried rebooting, still no luck. Is there something else that I may be missing? I start fluxbox through a one-line script (executed from the file in the wmsession.d directory) located at /usr/bin/startfluxbox. The line is: exec fluxbox Could it be the fact that I am using exec that is causing the .Xclients script not to be executed? Quote Link to comment Share on other sites More sharing options...
Guest SDMF Posted February 18, 2003 Report Share Posted February 18, 2003 Well, I got it to work, though not exactly the way that you suggested. What I did was I took the if statement from that I had previously put in /etc/X11/gdm/PreSession/Default, and put it in the /usr/bin/startfluxbox script, taking the su off of it. My startfluxbox script now looks something like this: fluxbox & wmpid=$! if [ -x /home/$USER/.Xclients ]; then sh /home/$USER/.Xclients fi wait $wmpid Quote Link to comment Share on other sites More sharing options...
theYinYeti Posted February 19, 2003 Report Share Posted February 19, 2003 That's strange. The only explanation I see is that your fluxbox script is not started by GDM in the standard GDM way... Yves. Quote Link to comment Share on other sites More sharing options...
Guest joehill Posted February 19, 2003 Report Share Posted February 19, 2003 there is a thread here on the pclinuxonline site, there is a link half way down to an rpm of fluxbox with the remember patch already applied. the advantage is that it should also create an entry in your gdm or kdm. the remember patch will allow you to have apps (say, dockapps) to run when flux starts by putting them in a startup entry in the menu. Quote Link to comment Share on other sites More sharing options...
Guest SDMF Posted February 19, 2003 Report Share Posted February 19, 2003 That's strange. The only explanation I see is that your fluxbox script is not started by GDM in the standard GDM way... Yves. Well, it is possible that I have not configured GDM 100% correctly. All I did was to create a file for fluxbox in /etc/X11/wmsession.d. Is there some other component somewhere in one of the X11 or X11R6 directories that needs to be added, or is the wmsession.d entry the only one necessary to correctly launch a WM from GDM? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.