Did you know LQ has a Linux Hardware Compatibility List?
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
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!


LinkBack Search this Thread
Old 06-06-2012, 04:14 PM   #1
LQ Newbie
Registered: Mar 2012
Distribution: Slackware 13.37 32-bit/win 7
Posts: 17

Rep: Reputation: Disabled
Add the xyz directory to your path (what path?)

I'm trying to install apache-ant at the moment and among the installation instructions is

"Add the bin directory to your path."

This isn't the first time I've come across this mysterious "path". What are they talking about?
should I just updatedb? do I have to put it in my fstab? what is required of me here?
Old 06-06-2012, 04:21 PM   #2
Senior Member
Registered: Nov 2002
Location: Toronto Canada
Distribution: Slackware 14.0 + 14.1
Posts: 4,777

Rep: Reputation: 415Reputation: 415Reputation: 415Reputation: 415Reputation: 415
They are talking about what directories the system will look through for your executable program.

The trick here is to find out what your 'path' is. The command is 'echo $PATH' enter the command without quotes in a terminal.

Here is what my system returns.

echo $PATH
So, if the executable is in /usr/local/bin or /usr/bin or /usr/games and the list goes on, the command will be found. If it is not in one of these directories, I can either update the path, or put a symlink in the path to the executable.

Hope this helps.
1 members found this post helpful.
Old 06-06-2012, 04:30 PM   #3
Senior Member
Registered: Nov 2010
Location: Colorado
Distribution: OpenSUSE, CentOS
Posts: 2,406

Rep: Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883Reputation: 883
As camorri said, the "path" is your PATH environment variable.

To add a directory to the path, stick the following in your startup script (depends on shell, for BASH it's usually ~/.bashrc):
export PATH=${PATH}:/path/to/new/directory
1 members found this post helpful.
Old 06-06-2012, 04:48 PM   #4
LQ Newbie
Registered: Mar 2012
Distribution: Slackware 13.37 32-bit/win 7
Posts: 17

Original Poster
Rep: Reputation: Disabled
thanks that solves it.


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
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] How to add a directory to PATH? wolfv Linux - General 2 01-26-2011 07:27 PM
Add directory to PATH JosephS Slackware 3 05-03-2008 10:17 AM
add a directory to PATH HarryBoy Linux - Newbie 5 05-02-2008 12:39 PM
Can't add directory to the PATH hpladd Linux - Newbie 5 07-25-2006 05:17 PM
I need to add a directory to the search path johnjafa Linux - Software 1 01-06-2005 01:43 PM

All times are GMT -5. The time now is 02:45 AM.

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