I want to search for a file pattern in more than one directory. How I need to do that?
Here is the scenario:
I am having a directory structure like the following:
/log
...../20051001
..........ftp_server_20051001.log
..........ftp_down_server.log
..........ftp_up_server.log... (7 Replies)
Hi,
filenames:
contains name of list of files to search in.
placelist
contains the names of places to be searched in all files in "filenames"
for i in $(<filenames)
do
egrep -f placelist $i
if ]
then
echo $i
fi
done >> outputfile
Output i am getting: (0 Replies)
I have multiple files that starts as TRADE_LOG spread across multiple folders in the given structure..
./dir1/1/TRADE_LOG*.gz
./dir2/10/TRADE_LOG*.gz
./dir11/12/TRADE_LOG*.gz
./dir12/13/TRADE_LOG*.gz
when I do ftp uisng mput from the "." dir I am getting the below given error
mput... (1 Reply)
need a Command in UNIX which can find out a word from files in multiple directories
e.g.
/home contains multiple directories
/home/d1
/home/d2
.
.
.
.
/home/dn
under d1,d2...dn contains multiple files. I need to search a specific word in a files under these multiple... (1 Reply)
Hi,
I have a directory /home/datasets/ which contains a bunch (720) of subdirectories called hour_1/ hour_2/ etc..etc.. in each of these there is a single text file called (hour_1.txt in hour_1/ , hour_2.txt for hour_2/ etc..etc..) and i would like to do some text processing in them.
Each of... (20 Replies)
Hi,
Very unfamiliar with unix/linux stuff. Our admin is on vacation so, need help very quickly.
I have directories (eg 40001, 40002, etc) that each have one subdirectory (01).
Each subdir 01 has multiple subdirs (001, 002, 003, etc). They are same in each dir.
I need to keep the top and... (7 Replies)
I have a list of files all over a file system e.g.
/home/1/foo/bar.x
/www/sites/moose/foo.txtI'm looking for strings in these files and want to replace each occurrence with a replacement string, e.g.
if I find: '#@!^\&@ in any of the files I want to replace it with: 655#@11, etc.
There... (2 Replies)
Hi,
Can someone please help me with a Command to Search a FILE for a STRING in multiple DIRECTORIES.
I am searching for the VIP in HTTPD.CONF in multiple httpd instances.
I am using
find ./ -name "httpd.conf" | xargs grep 10.22.0.141 cut -d: -f3- | cut -d ' ' -f4 | sort | uniq -c
... (1 Reply)
Lets say I have a massive directory which is filled with other directories all filled with different c++ scripts and I want a listing of all the scripts that contain the string: "this string". Is there a way to use a grep search for that? I tried:
grep -lr "this string" *
but I do not... (3 Replies)
Im having an issue when trying to replace the first column with a new set of values in multiple files. The results from the following code only replaces the files with the last set of values in val.txt. I want to replace all the files with all the values.
for date in {1..31}
do
for val in... (1 Reply)
Discussion started by: ncwxpanther
1 Replies
LEARN ABOUT HPUX
xsetfontpath
XSetFontPath() XSetFontPath()
Name
XSetFontPath - set the font search path.
Synopsis
XSetFontPath(display, directories, ndirs)
Display *display;
char **directories;
int ndirs;
Arguments
display Specifies a connection to an X server; returned from XOpenDisplay().
directories
Specifies the directory path used to look for the font. Setting the path to the empty list restores the default path defined for
the X server.
ndirs Specifies the number of directories in the path.
Description
XSetFontPath() defines the directory search path for font lookup for all clients. Therefore the user should construct a new directory
search path carefully by adding to the old directory search path obtained by XGetFontPath(). Passing an invalid path can result in pre-
venting the server from accessing any fonts. Also avoid restoring the default path, since some other client may have changed the path on
purpose.
The interpretation of the strings is operating-system-dependent, but they are intended to specify directories to be searched in the order
listed. Also, the contents of these strings are operating system specific and are not intended to be used by client applications.
An X server is permitted to cache font information internally, for example, it might cache an entire font from a file and not check on sub-
sequent opens of that font to see if the underlying font file has changed. However, when the font path is changed the X server is guaran-
teed to flush all cached information about fonts for which there currently are no explicit resource IDs allocated.
The meaning of errors from this request is implementation-dependent.
Errors
BadValue
See Also
XCreateFontCursor(), XFreeFont(), XFreeFontInfo(), XFreeFontNames(), XFreeFontPath(), XGetFontPath(), XGetFontProperty(), XListFonts(),
XListFontsWithInfo(), XLoadFont(), XLoadQueryFont(), XQueryFont(), XSetFont(), XUnloadFont().
Xlib - Fonts XSetFontPath()