Add Comment
|
Related Links
|
TrackBack
FileExists.sh (GPL)FileExists.sh is a Bourne Shell script that helps you determine whether any file that matches your specified file masks exists. This script will return 1 or 0, which represents true and false respectively. This script returns true when one or more files are found using any of the file masks you specified on the command-line. Using this script, your other scripts can easily determine whether some files exist. FileExists.sh is distributed as executable source code under the GNU General Public License. Please see the license agreement elsewhere on this site. UsageFileExists.sh mask1 [ . . . mask2 ] Examples: FileExists.sh "*.sh" Chieh Cheng By the way, you can use this utility to test for files that are not in the current directory. In fact, you can test for files in multiple directories and this utility will return '1' if the file mask is found in any of the specified directories. Following are some examples. ExamplesFileExists.sh "bin/*.java" Chieh Cheng what does 1 and 2 in line 25 stand for ??? debayan "-1" is a "ls" flag to display file names in a single column. "2>" redirects stderr; in this case, redirects to /dev/null, which just throws away the stderr output. Chieh Cheng Found an incompatibility issue with Ubuntu 12.10. This new attached version below resolves the incompatibility. Chieh Cheng
Add Comment
|
Related Links
|
TrackBack
Did your message disappear? Read the Forums FAQ. Add CommentSpam Control | * indicates required field TrackBackTrackBack only accepted from WebSite-X Suite web sites. Do not submit TrackBacks from other sites. Send Ping | TrackBack URL | Spam Control No TrackBacks yet. TrackBack can be used to link this thread to your weblog, or link your weblog to this thread. In addition, TrackBack can be used as a form of remote commenting. Rather than posting the comment directly on this thread, you can posts it on your own weblog. Then have your weblog sends a TrackBack ping to the TrackBack URL, so that your post would show up here. Messages, files, and images copyright by respective owners. |
Products
|
Services
41 Users Online
|
Copyright © 1996 - 2024. All Rights Reserved. |