Now on ScienceBlogs: Q: How do you sex a Smilodon? (A: Very carefully)

Seed Media Group

Greg Laden's Blog

Evolution, Life Sciences, Science Education, Human Evolution, and Stuff

Recent Comments

Profile


Welcome to Greg Laden's Blog.




Nature Blog Network



Search

Blogroll

Join the best atheist themed blogroll!
GLB_LOGO_180w.png
GLB_LOGO_180w.png
openlab08-submit.150.png



open_access_day_blog_award.jpg

Archives

Recent Posts

« Time to get organized on health care. | Main | New theory on Earth's Magnetic Field: Theory interesting, reporting botched »

How to grep a PDF file (Linux)

Category: Computer TricksLinuxOpenSourceTechnology
Posted on: June 14, 2009 4:29 PM, by Greg Laden

OK, I'm going to do this without looking. It will be something like pdftotext foo | grep whatever, right?

Let's watch and see....

Well, close enough. Note that that was not being done on a Debian system. For Debian (like Ubuntu) you would use apt to install the tools.

apt-get install poppler-utils


Share this: Stumbleupon Reddit Email + More

TrackBacks

TrackBack URL for this entry: http://scienceblogs.com/mt/pings/111992

Comments

1

Or xpdf-utils, Poppler being a fork of Xpdf.

Posted by: Barry | June 14, 2009 7:47 PM

2

Wouldn't it just be easier to open the pdf and search for the phrase? Then you'd know the context as well as the location of the string. I'm sympathetic to the wonders of the command line, but this looks like a fair amount of work.

Posted by: richard | June 14, 2009 9:13 PM

3

richard, suppose you are searching through 1000 pdf's of articles you snagged over the last few years? This can be a batch operation over many files this way.

Posted by: Markk | June 14, 2009 10:46 PM

4

Oh, gosh, you linux-people are a never ending source of mirth :-)

Posted by: Michael Spencer | June 15, 2009 7:03 AM

Post a Comment

(Email is required for authentication purposes only. On some blogs, comments are moderated for spam, so your comment may not appear immediately.)





ScienceBlogs

Search ScienceBlogs:

Go to:

Advertisement
Follow ScienceBlogs on Twitter
Visit the Collective Imagination blog
Advertisement

© 2006-2009 Seed Media Group LLC. ScienceBlogs is a registered trademark of Seed Media Group. All rights reserved.

Sites by Seed Media Group: Seed Media Group | ScienceBlogs | SEEDMAGAZINE.COM