Download your favorite Linux distribution at LQ ISO.
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!


  Search this Thread
Old 03-16-2009, 07:36 PM   #1
LQ Newbie
Registered: Mar 2009
Posts: 1

Rep: Reputation: 0
Using the addpath command


I'm a very new Linux user, I'd like to develop my knowledge of it more in the future but at the moment Im using it to process GPS data.

I need to add a path in my home directory to a piece of matlab software elsewhere on the network.

Iknow the command I need is something like
but when I use this it says the brackets are badly placed?

Can any body tell me what Im doing wrong?
Im using Fedora

If I havent given you enough information then no worrys,
I really am very new to this!! Just wondering if anybody could help!


Old 03-16-2009, 08:16 PM   #2
Registered: Mar 2009
Distribution: Fedora, Slackware
Posts: 104

Rep: Reputation: 21
The 'addpath' is not a common tool - at least I think so, because it's not part of any Linux system that I used so far (it's also not on my current Fedora). Generally
is the method to add a new entry to your $PATH variable, where each path segment is separated by colons.

Your posting said that you want to "add a path in my home directory to a piece of matlab software" - adding a path to an application is different thing. For that you will need to use the application's preference interface or configuration file, I guess.


Linux Archive

Last edited by JaksoDebr; 04-02-2009 at 06:16 AM.
Old 03-16-2009, 09:21 PM   #3
Registered: Oct 2008
Location: Brisbane Australia
Distribution: Fedora, Centos
Posts: 268

Rep: Reputation: 54
You would edit the .bash_profile file in your home directory and add extra paths inot the PATH= line
For example, as JacksoDebr said above you might do something like this:-


Don't forget to export PATH. In the bash shell all you really have to do is :-

export PATH=$PATH:/path/to/matlab-script

The first $PATH means expand any previous PATH value and then the ":" says append my extra PATH info.
Old 03-16-2009, 11:50 PM   #4
John VV
LQ Muse
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,225

Rep: Reputation: 2521Reputation: 2521Reputation: 2521Reputation: 2521Reputation: 2521Reputation: 2521Reputation: 2521Reputation: 2521Reputation: 2521Reputation: 2521Reputation: 2521
adding it to the .bash_profile is the best way
it will work just fine if all you need is the location to the executable file ( /home/YourUserName/mathLab/someFolder
and for most things that will work .But some programs will also need a "LD_LIBRARY_PATH" or LIBDIR or LD_RUN_PATH added to that file and to be exported

if just adding the path to the program dose not work please post the error .

PS. after you add it you MUST log out and log back in again for the change to work .


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
Is there a single command to list all hardware installed (command line)? davee Linux - Hardware 6 02-28-2009 08:19 PM
busybox command works, same command within script says permission denied jeroenv Linux - Newbie 2 01-17-2009 03:58 AM
LXer: The Linux Command Shell For Beginners: Fear Not The Command Line! LXer Syndicated Linux News 0 12-22-2008 07:30 PM
My error in mkisofs command to make a command line iso mg92865 Linux - Newbie 1 06-20-2008 12:43 PM
Key stroke/command to shut down x and go into the command prompt screen? Fear58 Linux - General 1 07-14-2004 08:14 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:18 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration