LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 05-06-2005, 02:09 AM   #1
jasone
Member
 
Registered: Oct 2004
Location: Sweden
Distribution: FreeBSD, OpenBSD, Debian Etch
Posts: 160

Rep: Reputation: 30
Symbolic link?


Hello!

I have in my /usr/bin a file called btdownloadxterm.sh which I would like to be able to start from wherever I'm located (ex. /home/myuser) with the command bt or bitttorrent. How do I do this? Is this what's called a symbolic link?

Thanks!
 
Old 05-06-2005, 02:27 AM   #2
chii-chan
Member
 
Registered: Sep 2003
Location: chikyuu (E103N6)
Distribution: Redhat 8.0 (2.4.25-custom), Fedora Core 1 (2.4.30-custom)
Posts: 357

Rep: Reputation: 30
Code:
ln -s /usr/bin/btdownloadxterm.sh /usr/bin/bt
will do.

ln - the linking program.
-s - the option to softlink the first parameter (/usr/bin/btdownloadxterm.sh) to the second parameter (/usr/bin/bt). With this you'll only need to type 'bt' in command line.

Search for "soft linking" in Google for more info (I know 'man ln' is quite confusing).
 
Old 05-06-2005, 07:06 AM   #3
bnj
Member
 
Registered: Apr 2005
Location: Switzerland
Distribution: Ubuntu
Posts: 70

Rep: Reputation: 15
Normally, /usr/bin should be in your path. So you should be able to launch the programm by just typing (no matter in which directory you currently are) the name of the script.

To check whether /usr/bin is in your path, type

> echo $PATH

if the output contains /usr/bin between two ':' or at the beginning or at the end, it should work fine. If not, add it to you path. The command for that is

> setenv PATH "/usr/bin:"$PATH

(if you are using tc shell). Then, to make sure it will be included in your path whenever you open a new shell, add the same line to a file called .tcshrc in your home directory. If this file does not exist, create it.
 
Old 05-06-2005, 07:07 AM   #4
bnj
Member
 
Registered: Apr 2005
Location: Switzerland
Distribution: Ubuntu
Posts: 70

Rep: Reputation: 15
By the way, make sure the script is executable:

> chmod 700 /usr/bin/btdownloadxterm.sh
 
Old 05-06-2005, 07:55 AM   #5
jasone
Member
 
Registered: Oct 2004
Location: Sweden
Distribution: FreeBSD, OpenBSD, Debian Etch
Posts: 160

Original Poster
Rep: Reputation: 30
Thank you! I'll check that out. Didn't know anything about path's before. I'm using slackware and my path to xorgconfig doesn't work so I guess there is some more things I'll have to change..
 
  


Reply


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
What is a Symbolic Link? little_penguin Linux - Software 2 05-14-2005 09:27 AM
symbolic link ilnli Slackware 6 01-04-2005 05:05 PM
help with a symbolic link mykrob Linux - Software 6 11-22-2004 10:01 AM
Symbolic link. bulzbb Linux - General 8 03-19-2004 04:57 AM
Symbolic link bwaynej2002 Linux - General 8 08-25-2003 10:06 PM


All times are GMT -5. The time now is 11:36 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