Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

tirwit

macrumors newbie
Original poster
Jan 20, 2010
28
0
Hi!

I'm kinda new to this part of informatics so my question will look dumb... My apologies in advance.

I need to work with a chart of nuclides which I found in http://www.yoix.org/sw/tools/yoix/elements.html

I downloaded the Yoix Installer which supposedly brings the application (the link is on that webpage too). But in the bottom of the page you find this:

If the script is in your execution PATH, then it can be invoked from the command-line as follows:
ychart_elements

But how do I do that? I mean... What's the PATH and what (and how do I do it?) is adding the script to it?

I'm still undergraduate engineering physics student, so informatics it's not my strong point :confused:

Thanks :)
 
You can run the script from wherever it is located (I will assume it is just in your home directory) by adding a ./ in front of it as in:
./ychart_elements

To actually add it to your $PATH you can do the following
export PATH=/location/of/script/directory:$PATH

This will add it temporarily to your $PATH. If you edit the .bash_profile file hidden in your directory and add that line there it will become permanent. You can just add it at the bottom of the file.

Another easy way to do this is just create a folder called "bin" (without the quotes) in your home directory, then put the script in there and I believe that OSX automatically adds it to your path once you log out and log back in again.

If it doesn't seem to be working after you do any of the above, you may have to set the script to be executable. To do this from the terminal just type:
chmod +x ychart_elements

Some scripts are not set as executable when you download them.

Here is a link to an article about setting your $PATH:
http://www.tech-recipes.com/rx/2621/os_x_change_path_environment_variable/



Cheers
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.