Sponsored Content
Full Discussion: PATH dircetory search order
Top Forums Shell Programming and Scripting PATH dircetory search order Post 302272804 by jwzumwalt on Thursday 1st of January 2009 02:35:59 AM
Old 01-01-2009
Just a quick comment. I occasionally use cygwin but don't know how close to a real unix shell it is.

1-With a real shell the directories are searched in the order they are found in the path statement.
So PATH="/a:/b/1:etc..." the /a will be looked at first.

2-Dont forget to EXPORT your path! About once a week I work an extra 15min on a problem because I forgot to EXPORT the varaiable.

3-You may not have complete control of the path under Cygwin because MS Win may do some of its own hunting before the Cygwin path statement takes place. You will have to do some quick tests Smilie

I hope this helps you consider some options....
JZ
 

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

home directory in search path

Is it unsafe to put your own home directory (a regular user) in your search path? I am writing useful shell scripts, but don't have the permissions to put them in /usr/bin. (Korn shell) thanks (2 Replies)
Discussion started by: jpprial
2 Replies

2. UNIX for Dummies Questions & Answers

Adding default search path for CPP

Hi there, I have built myself a GCC (3.4.4) for PowerPC with a cross compilation toolchain running on a x86, together with glibc-2.3.4 and binutils-2.16. On the PowerPC there is a system runnign already (only console ofc, nothing "cosy", kernel-2.6.15). So my question is how to propperly... (1 Reply)
Discussion started by: boyanov
1 Replies

3. Shell Programming and Scripting

grep - search order

Hi, I would like "grep" command to search ALL files in current directory in the order of their modified/created date. How can i do this? e.g., if 3 files contain the pattern i am searching for, i need the output of "grep" to be in the order such that old file search result should come first.... (6 Replies)
Discussion started by: prvnrk
6 Replies

4. Shell Programming and Scripting

How to find duplicate commands in the search path?

I wanted to see if there is any duplicate of a specific command in the command search path. The following code will list all copies of "openssl" in the command search path. find `printenv PATH | sed "s/:/ /g"` -maxdepth 1 -name openssl However, the above code would fail if the search path... (9 Replies)
Discussion started by: LessNux
9 Replies

5. Shell Programming and Scripting

How to select the shortest path in grep search?

Hi, How can I display only one shortest path (A/B/configure)? $ grep configure file.txt A/B/configure A/B/C/configure A/B/C/D/configure Thank you. (9 Replies)
Discussion started by: hce
9 Replies

6. Shell Programming and Scripting

Conduct a search or test -f over a path with spaces

I am organizing my music library on a NAS server. I want to print a list of all the directories that are missing the cover art (at least one or more jpeg file). I have successfully created a file with each line containing the path to each occurance of one or more .mp3 files. That path is also... (2 Replies)
Discussion started by: godfreydanials
2 Replies

7. UNIX for Dummies Questions & Answers

How to add to the search path - bin?

Hi, Now I have: /Users/okn/bin for my private shell scripts. How do I add /Users/okn/bin to my PATH? The PATH is right now: /usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin The .bash_profile doesn't state anything about a PATH (yet). I read about this: PATH=/bin:$PATH
 export PATH or... (1 Reply)
Discussion started by: OmarKN
1 Replies

8. Programming

Gcc linker search path order

I have a build where I wish to link against and load a specific version of a library and a different version of the same library is installed on the system. I'm using a -L option to point to the version that I wish to link against but gcc still seems to choose the installed version. Is there a way... (4 Replies)
Discussion started by: Richard Johnson
4 Replies

9. Shell Programming and Scripting

Php search path

Probably simple, but I don't see it. jack@veritron /u/email $ cat p3.php <?php require_once './lib/swift_required.php'; $x=get_include_path(); echo "$x \n"; set_include_path('./lib:./lib/classes:'.$x); $x=get_include_path(); echo "$x \n"; $transport =... (1 Reply)
Discussion started by: jgt
1 Replies
GST-PACKAGE(1)							   User Commands						    GST-PACKAGE(1)

NAME
gst-package - create and install GNU Smalltalk .star package files DESCRIPTION
Usage: gst-package [OPTION]... ARGS... Operation modes: --install make or install STAR packages (default) --uninstall remove the packages mentioned in the FILES --dist copy files instead of creating STAR files. --prepare create configure.ac or Makefile.am --list-files PKG just output the list of files in the package --list-packages just output the list of packages in the files --download, --update download package from smalltalk.gnu.org or from its specified URL --help display this message and exit --version print version information and exit Common suboptions: -n, --dry-run print commands without running them --srcdir DIR look for non-built files in directory DIR --distdir DIR for --dist, place files in directory DIR --destdir DIR prefix the destination directory with DIR --target-directory DIR install the files in DIR (unused for --dist) -I, --image-file=FILE load into the specified image --kernel-dir=PATH use the specified kernel directory -v, --verbose print extra information while processing --install suboptions: --test run unit tests after merging --load also load the Smalltalk files in the image --list-files suboptions: --load only list files that are filed in when loading --test with --load, also include unit test files --vpath Omit path to srcdir for files that are there --dist suboptions: --all-files Process all files, not just non-built ones --copy Do not create symbolic links All operation modes except --download (or its synonym --update) accept paths to package.xml files or .star files, including remote URLs. --download and --update accept names of packages, which will be searched in the current system or on smalltalk.gnu.org) or URLs to pack- age.xml or .star files. Except in uninstall and list files mode, gst-package requires write access to the GNU Smalltalk image directory, and merges the XML package files on the command line with that file. The default target directory is /build/buildd-gnu-smalltalk_3.2.4-2-amd64-LVoFQd/gnu-smalltalk-3.2.4 SEE ALSO
The full documentation for gst-package is maintained as a Texinfo manual. If the info and gst-package programs are properly installed at your site, the command info gst should give you access to the complete manual. gst-package version 3.2.4 December 2011 GST-PACKAGE(1)
All times are GMT -4. The time now is 03:12 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy