Register a domain and help support LQ
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 09-29-2008, 07:27 AM   #1
Registered: Sep 2008
Location: America
Distribution: Debian
Posts: 33

Rep: Reputation: 16
Question What is wrong with this diff command?

I am having trouble using the diff command correctly. I am using the following.

jb_get@jonesey:~/logs> diff  --unchanged-line-format= --new-line-format=  `find $myPath -type f -name "ip_summary-*" |sort -r |head -2` > /tmp/zGzb$$
but i keep getting this output

diff: missing operand after `--new-line-format='
diff: Try `diff --help' for more information.
Can someone tell me what I am doing wrong?

Thank you.

Last edited by Tinkster; 09-16-2010 at 01:20 PM.
Old 09-29-2008, 03:16 PM   #2
Registered: Jun 2008
Posts: 235

Rep: Reputation: 46

are you sure, that your find/sort/head pipe returns 2 pathnames? I get the error message if no files are found.

Old 10-01-2008, 09:27 AM   #3
Registered: Sep 2008
Location: America
Distribution: Debian
Posts: 33

Original Poster
Rep: Reputation: 16
I found where my problem was. When i searched for my files that were being created I was searching for "ip_summary-*" when in fact it should have been "ip_summary_*"...silly me

Thanks for the help


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Question on diff command just.srad Programming 4 04-05-2008 05:01 AM
How to avoid some differences in Diff command rajbal Linux - General 3 04-11-2007 12:28 AM
How to use 'diff' command ursusman Linux - Newbie 1 03-08-2007 05:29 AM
diff command on a config file samyboy Linux - General 8 01-31-2007 03:44 AM
help on diff command anandss2004 Programming 2 11-01-2005 01:58 PM

All times are GMT -5. The time now is 03:21 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration