Sponsored Content
Full Discussion: Find files in Directories
Top Forums Shell Programming and Scripting Find files in Directories Post 68263 by sglinux on Saturday 2nd of April 2005 05:27:37 AM
Old 04-02-2005
find . -type f -print | grep file.txt
find * -type f -print | grep file.txt
find / -type f -print | grep file.txt
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

find -type d returning files as well as directories

Can anyone see why the following command returns all files and not just the directories as specified? find . -type d -exec ls -F {} \; Also tried find . -type d -name "*" -exec ls -F {} \; find . -type d -name "*" -exec ls -F '{}' \; -print Always returns all files :-\ OS is... (2 Replies)
Discussion started by: tuns99
2 Replies

2. Homework & Coursework Questions

Find and delete empty files and directories

Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted! 1. The problem statement, all variables and given/known data: Need to make a script, to remove all empty files and folders from current category. It also should show the name... (2 Replies)
Discussion started by: Itixop
2 Replies

3. Shell Programming and Scripting

Find Files with a input in directories

So i have directories that store logs, 1 directorie for each day, with the name like this : 2012_07_01/ 2012_07_02/ and for each directorie we have the logs, inside them lives the logs for that day, and every log have this name pattern : ... (2 Replies)
Discussion started by: drd0spt
2 Replies

4. Shell Programming and Scripting

Script to go Into Directories and Find/Delete files

I have a task, I usually do manually, but with growing responsibilities I tend to forget to do this weekly, I want to write a script that automates this, but I cant seem to work it out in my head, I have the shell of it out, but need help, and you guys have helped me with EVERY problem I have... (5 Replies)
Discussion started by: gkelly1117
5 Replies

5. Shell Programming and Scripting

Find only files/directories with different permissions/owners

My git post-update has the following lines in it to make sure the permissions are set right: find /usr/local/apache/htdocs -type d -print0 | xargs -0 chmod 755 find /usr/local/apache/htdocs -type f -print0 | xargs -0 chmod 644 chown -R apache:apache /usr/local/apache/htdocsThe only problem is... (5 Replies)
Discussion started by: dheian
5 Replies

6. UNIX for Advanced & Expert Users

Find all files in the current directory excluding hidden files and directories

Find all files in the current directory only excluding hidden directories and files. For the below command, though it's not deleting hidden files.. it is traversing through the hidden directories and listing normal which should be avoided. `find . \( ! -name ".*" -prune \) -mtime +${n_days}... (7 Replies)
Discussion started by: ksailesh1
7 Replies

7. UNIX for Dummies Questions & Answers

Find Files In A List with known Partial Directories

First I'm new to Linux and have used the find command pretty often but this is where I've hit a snag. I have a file that contains 3500 files that I want to find and then eventually copy to my own directory (these files are all on a shared directory at work atm). Our work computer are huge and... (2 Replies)
Discussion started by: Myrona
2 Replies

8. UNIX for Dummies Questions & Answers

Loop over certain user directories and find files

Hello I have user directories that contain /temp directory. Example folders: /user1/temp/ /user2/temp/ /user3/temp/ How can i loop over all user directories and find all files only in their /temp folder? Thanks a lot for help! (3 Replies)
Discussion started by: flavius42
3 Replies

9. Shell Programming and Scripting

Find common files between two directories

I have two directories Dir 1 /home/sid/release1 Dir 2 /home/sid/release2 I want to find the common files between the two directories Dir 1 files /home/sid/release1>ls -lrt total 16 -rw-r--r-- 1 sid cool 0 Jun 19 12:53 File123 -rw-r--r-- 1 sid cool 0 Jun 19 12:53... (5 Replies)
Discussion started by: sidnow
5 Replies

10. Shell Programming and Scripting

Find command excluding directories and some files

hello. I try to print a list of files but excluding some directories and some files. I would like to write a command for : find "from_dir" "ignore dir1, dir2, ..." "ignore file1, file2,...." "where file are older than 2017-02-03T06:00:00" Note that "DO_IT" is a local function in the script... (5 Replies)
Discussion started by: jcdole
5 Replies
XSetFontPath(3X11)						     MIT X11R4							XSetFontPath(3X11)

Name
       XSetFontPath, XGetFontPath, XFreeFontPath - set, get, or free the font search path

Syntax
       XSetFontPath(display, directories, ndirs)
	  Display *display;
	  char **directories;
	  int ndirs;

       char **XGetFontPath(display, npaths_return)
	  Display *display;
	  int *npaths_return;

       XFreeFontPath(list)
	  char **list;

Arguments
       directories
		 Specifies the directory path used to look for a font.	Setting the path to the empty list restores the default path defined for
		 the X server.

       display	 Specifies the connection to the X server.

       list	 Specifies the array of strings you want to free.

       ndirs	 Specifies the number of directories in the path.

       npaths_return
		 Returns the number of strings in the font path array.

Description
       The function defines the directory search path for font lookup.	There is only one search path per X server, not one per client.  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 dependent and are not intended to be used by client applications.  Usu-
       ally, the X server is free to cache font information internally rather than having to read fonts from files.  In addition, the X server is
       guaranteed to flush all cached information about fonts for which there currently are no explicit resource IDs allocated.  The meaning of an
       error from this request is operating system dependent.

       can generate a error.

       The function allocates and returns an array of strings containing the search path.  When it is no longer needed, the data in the font path
       should be freed by using

       The function frees the data allocated by

Diagnostics
       Some numeric value falls outside the range of values accepted by the request.
		 Unless a specific range is specified for an argument, the full range defined by the argument's type is accepted. Any argument
		 defined as a set of alternatives can generate this error.

See Also
       XListFont(3X11), XLoadFonts(3X11)
       X Window System: The Complete Reference, Second Edition, Robert W. Scheifler and James Gettys

																XSetFontPath(3X11)
All times are GMT -4. The time now is 03:44 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy