Solved

find: incomplete statement

Posted on 2006-11-22
3
957 Views
Last Modified: 2013-12-26
Hi ,
  Am trying to run the following command :
  find . -exec grep -i 'Header' {} ; -print > $HOME/xmlver.txt
  to get me the header information for all files in a certain directory , but the problem is that it ends with the error sayin find: incomplete statement ..

  is there anything wrong with the command , please advise .

Regards.
0
Comment
Question by:Dr_Billy
3 Comments
 
LVL 11

Accepted Solution

by:
cjjclifford earned 125 total points
ID: 17997486
you need to terminate the "grep" command with a \;

i.e. you need to escape out the semi-colon

i.e.

find . -exec grep -i 'Header' {} \; -print > $HOME/xmlver.txt
0
 
LVL 58

Expert Comment

by:amit_g
ID: 17997506
Add a \ before ;

find . -exec grep -i 'Header' {} \; -print > $HOME/xmlver.txt
0
 
LVL 8

Expert Comment

by:koppcha
ID: 17998480
find . -exec grep -i 'bin' {} \; > $HOME/xmlver.txt
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Question regarding Copy/Paste 16 96
substring method in java 1 129
has22 challenge 11 104
haveThree challenge 22 121
In this article, I'll describe -- and show pictures of -- some of the significant additions that have been made available to programmers in the MFC Feature Pack for Visual C++ 2008.  These same feature are in the MFC libraries that come with Visual …
Introduction: Dynamic window placements and drawing on a form, simple usage of windows registry as a storage place for information. Continuing from the first article about sudoku.  There we have designed the application and put a lot of user int…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

808 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question