473,398 Members | 2,403 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,398 software developers and data experts.

how to find the particular string in unix

11
Hi

how to find particualr string in current directory and all sub directories in unix(command promt).

please help

bye
gupta
Aug 5 '08 #1
3 9691
Are you trying to find a string of characters in a file? Try grep.

grep -r "whateveryourlookingfor" *
Aug 5 '08 #2
gupta24
11
yes correct but i want searching particular parttern string not only in current directory we find also enitre sub directoryies also



please help
bye
gupta



Are you trying to find a string of characters in a file? Try grep.

grep -r "whateveryourlookingfor" *
Aug 6 '08 #3
mac11
256 100+
yes correct but i want searching particular parttern string not only in current directory we find also enitre sub directoryies also



please help
bye
gupta
billyguy gave you what you needed - check the manpage for grep 'man grep' , the "-r" makes it recurse into subdirectories
Aug 6 '08 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

12
by: hokiegal99 | last post by:
The below code does what I need it to do, but I thought that using something like ext = os.path.splitext(fname) and then searching ext for '.mp3' would be a much more accurate approach to solving...
1
by: Xah Lee | last post by:
suppose you want to do find & replace of string of all files in a directory. here's the code: ©# -*- coding: utf-8 -*- ©# Python © ©import os,sys © ©mydir= '/Users/t/web'
0
by: jeremit0 | last post by:
I have read a text file using the command lines = myfile.readlines() and now I want to seach those lines for a particular string. I was hoping there was a way to "find" that string in a...
4
by: Rafal 'Raf256' Maj | last post by:
jak znalezc dany string w TMemo (i przejsc do niego), jak przejsc (tzn odpowiednio przewinac scrollbary i ustawic kursor) do danej linii tekstu (np. numer 123) --...
1
by: Bart Masschelein | last post by:
Hello, I have a VC++ project which uses files located on my Unix account Browsing (eg. go to Definition etc) works fine, however, if I use "Fin in Files" it does not find any single instance of...
5
by: Joerg Battermann | last post by:
Hello there, I have a custom type defined via Public Class Requirement Public IDNumber As Integer Public Name As String Public Description As String Public VersionPlanAttributes As New _
3
by: Cplusplusbeginner | last post by:
I need to write a program to search a particular string in a specific file.e.g if the file is abc.dat which contains names of students in a class, I need to search for a particular name say John in...
2
by: Rahul Babbar | last post by:
Hi, I was curious if i could find what process id of the host system(AIX) was associated with a particular agent id provided by the database. Can anybody tell if such a pid can be found out. ...
0
by: Gabriel Genellina | last post by:
En Wed, 20 Aug 2008 17:10:15 -0300, aditya shukla <adityashukla1983@gmail.comescribió: You have 3 leading underscores in __main__ so the if statement is skipped and nothing happens. I'd use the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.