Mandriva This Forum is for the discussion of Mandriva (Mandrake) Linux. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
08-21-2004, 07:45 AM
|
#1
|
LQ Newbie
Registered: Aug 2004
Posts: 12
Rep:
|
Bash aliases won't autostart?
I know, I know, this is my about hundreth post about Konquaror autostart, but I just don't get it  I have a working bash alias, the alias is named "liput". The .bashrc file reads like this:
alias liput="python rm.py -c 1 4"
How should I define the command in the Konqueror autostart to get the alias to start when kde starts? I have tried everything, and nothing actually works. But like a miracle, when manually using from terminal, the alias works like a charm. Any clues? I promise this was my last post concerning tha Autostart "feature"!
-Olli
|
|
|
08-21-2004, 09:14 AM
|
#2
|
Senior Member
Registered: Nov 2002
Location: pikes peak
Distribution: Slackware, LFS
Posts: 2,577
Rep:
|
Code:
alias liput='python rm.py -c 1 4'
try using single quotes...........like you see above
|
|
|
08-21-2004, 09:22 AM
|
#3
|
Member
Registered: May 2004
Location: Pennsylvania, USA
Distribution: dual boot.... Mandrake 10.0OE/10.xcooker
Posts: 611
Rep:
|
i don't know much about alias or bashrc, but have you tried just creating a symlink to the executable that you want to autostart, in the autostart directory? you can do it 2 ways...........
GUI method........
open Konqueror in normal (not root) file manager mode. navigate to the /.kde/autostart directory. on the top tool bar, click edit->create new->file->link to application. under "general" give it a name of your choice, under "application" name it the same, then in the "command" box, browse to the executable, put any special switches you might want to use, click "ok" when done.
terminal method..........
open a terminal, as normal user cd to /.kde/autostart. then type the following..........
ln -s /path/to/executable (hit enter)
where /path/to/executable is the path to the executable you want to run. you can also add any switches you want to use in the path.
otis
EDIT: oops............ i see 320mb has a suggestion too. as i said i'm not real familiar with aliases or bashrc, so try his suggestion first, as that might be a better way.
Last edited by otish1000c; 08-21-2004 at 09:25 AM.
|
|
|
08-21-2004, 09:25 AM
|
#4
|
LQ Newbie
Registered: Aug 2004
Posts: 12
Original Poster
Rep:
|
The alias works fine from terminal, but I cannot get it to work as an "link to application" in .kde/Autostart/ -directory. So it can't be the quotes, I think. I just need to know how the simple liput -command should be entered to the "command" -field in the "link to application" properties window.
-Olli
|
|
|
08-22-2004, 12:45 AM
|
#5
|
Member
Registered: Jun 2004
Location: Kansas City, MO
Distribution: Fedora (LXQT)
Posts: 276
Rep:
|
i had to make a bash script for setiathome, maybe you need to do something similar. I put my alias after the call to /etc/bashrc for some reason the etc/bashrc would overwrite my alias. as to your shell script you can make
#!/bin/bash
python rm.py -c 1 4 &
then make a desktop icon link to application, then do
mv /home/[username]/Desktop/[application link name] /home/[username]/.kde/Autostart
and it should work for you. I know it's a bit of a hack, but it should work, if you want the program to autostart for you.
Btw, i use this method to make my background picture have rxvt running transparently over it.
|
|
|
08-22-2004, 03:04 AM
|
#6
|
LQ Newbie
Registered: Aug 2004
Posts: 12
Original Poster
Rep:
|
Thanks for your input people  However, it just don't work... I didi both te ways you suggested and it basically gives me this error "exec failed: not a directory" I created this shell-script:
#!/bin/bash/
python rm.py -c 1 4 &
saved it as rm.sh and created a link to it. The name of the link was rm and the application field was also named a rm. It won't work by clicking or at kde startup, though it's in the .kde/Autostart -directory. I can't understand, what can be wrong. This seems to unnecessary, because the actual problem should be like making a cup of coffee. (that can be pretty hard too some times
The file rm.sh is in my home directory, so there should be no problems with access priviledges.
Bear with me,
Olli
|
|
|
08-22-2004, 08:09 AM
|
#7
|
Member
Registered: May 2004
Location: Pennsylvania, USA
Distribution: dual boot.... Mandrake 10.0OE/10.xcooker
Posts: 611
Rep:
|
Quote:
The file rm.sh is in my home directory, so there should be no problems with access priviledges.
|
just because something is in /home, doesn't neccessarily mean that it has user priveledges. if it was created as root, it could/would have root permissions. i'd check that, just to be sure. right click the file, check the permissions tab, change if neccessary.
otis
|
|
|
08-22-2004, 02:10 PM
|
#8
|
Member
Registered: Jun 2004
Location: Kansas City, MO
Distribution: Fedora (LXQT)
Posts: 276
Rep:
|
I see the problem, you may not have python in a place in your path, you might have to edit your script thusly:
#!/bin/bash
/usr/bin/python /home/[username]/rm.py -c 1 4 &
then to make it run in kde, make the icon on your desktop, to create a rm.desktop object to do a
mv /home/[username]/Desktop/km.desktop /home/[username]/.kde/Autostart/km.desktop
assuming you name your desktop icon rm
|
|
|
All times are GMT -5. The time now is 07:19 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|