<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Regular expressions and search patterns</title>
	<atom:link href="http://polishlinux.org/console/regular-expressions-and-search-patterns/feed/" rel="self" type="application/rss+xml" />
	<link>http://polishlinux.org</link>
	<description>All About GNU/Linux and BSD - reviews, comparisons, articles</description>
	<lastBuildDate>Wed, 19 Jun 2013 21:36:56 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
	<item>
		<title>By: Celine</title>
		<link>http://polishlinux.org/console/regular-expressions-and-search-patterns/#comment-199016</link>
		<dc:creator>Celine</dc:creator>
		<pubDate>Tue, 01 May 2012 16:02:15 +0000</pubDate>
		<guid isPermaLink="false">http://polishlinux.org/console/regular-expressions-and-search-patterns/#comment-199016</guid>
		<description><![CDATA[thanks a lot!http://www.listadeemail.org]]></description>
		<content:encoded><![CDATA[<p>thanks a lot!<a href="http://www.listadeemail.org" rel="nofollow">http://www.listadeemail.org</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gaurav miglani</title>
		<link>http://polishlinux.org/console/regular-expressions-and-search-patterns/#comment-124043</link>
		<dc:creator>Gaurav miglani</dc:creator>
		<pubDate>Wed, 10 Sep 2008 06:46:23 +0000</pubDate>
		<guid isPermaLink="false">http://polishlinux.org/console/regular-expressions-and-search-patterns/#comment-124043</guid>
		<description><![CDATA[gr8 article!!
simple and pretty comprehensive...
thanks!!]]></description>
		<content:encoded><![CDATA[<p>gr8 article!!<br />
simple and pretty comprehensive&#8230;<br />
thanks!!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: lieven</title>
		<link>http://polishlinux.org/console/regular-expressions-and-search-patterns/#comment-59993</link>
		<dc:creator>lieven</dc:creator>
		<pubDate>Tue, 25 Sep 2007 11:47:44 +0000</pubDate>
		<guid isPermaLink="false">http://polishlinux.org/console/regular-expressions-and-search-patterns/#comment-59993</guid>
		<description><![CDATA[I think there&#039;s another typo:
Didn&#039;t you forget the backslash?


find . -size +110M -size -150M -exec cp {} /home/adam/files/ \;

This article is great. Maybe the best I&#039;ve read on the
subject. Thanks...]]></description>
		<content:encoded><![CDATA[<p>I think there&#8217;s another typo:<br />
Didn&#8217;t you forget the backslash?</p>
<p>find . -size +110M -size -150M -exec cp {} /home/adam/files/ \;</p>
<p>This article is great. Maybe the best I&#8217;ve read on the<br />
subject. Thanks&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: LightningCrash</title>
		<link>http://polishlinux.org/console/regular-expressions-and-search-patterns/#comment-59984</link>
		<dc:creator>LightningCrash</dc:creator>
		<pubDate>Tue, 25 Sep 2007 11:02:35 +0000</pubDate>
		<guid isPermaLink="false">http://polishlinux.org/console/regular-expressions-and-search-patterns/#comment-59984</guid>
		<description><![CDATA[No mention of sed or perl?

Also, you don&#039;t have to pipe find to xargs for an rm. -delete works just as well.

Btw, ls and rm don&#039;t actually accept regexps. They will, however, accept globbing from bash, which is what your examples end up producing.

Regexps can also strip HTML from files, ie
cat file.html&#124;sed -e &#039;s/]*&gt;//g&#039; &gt;&gt; file.txt

You can also make find&#039;s -regex option case insensitive by making it -iregex. This is handy when you&#039;re searching through a mixed environment of upper case and lower case file extensions like jpg and JPG.

And don&#039;t forget, the rename command also accepts regexps!
For instance, if you want to change the case of some JPG files to lower case:

cd ~/photos/dirwithphotos
rename &#039;s/JPG$/jpg/&#039; *.JPG

Done.
You can go further with it, too. For instance, if I want to change the first part of the filename, since they’re all named IMG_0123.JPG

cd ~/photos/icanhaslinux
rename &#039;s/^IMG/icanhaslinux/&#039; *
rename &#039;s/JPG$/jpg&#039; *

It accepts very sed-like regexp behavior.

Anyway, that&#039;s all for now!
-LightningCrash]]></description>
		<content:encoded><![CDATA[<p>No mention of sed or perl?</p>
<p>Also, you don&#8217;t have to pipe find to xargs for an rm. -delete works just as well.</p>
<p>Btw, ls and rm don&#8217;t actually accept regexps. They will, however, accept globbing from bash, which is what your examples end up producing.</p>
<p>Regexps can also strip HTML from files, ie<br />
cat file.html|sed -e &#8216;s/]*&gt;//g&#8217; &gt;&gt; file.txt</p>
<p>You can also make find&#8217;s -regex option case insensitive by making it -iregex. This is handy when you&#8217;re searching through a mixed environment of upper case and lower case file extensions like jpg and JPG.</p>
<p>And don&#8217;t forget, the rename command also accepts regexps!<br />
For instance, if you want to change the case of some JPG files to lower case:</p>
<p>cd ~/photos/dirwithphotos<br />
rename &#8216;s/JPG$/jpg/&#8217; *.JPG</p>
<p>Done.<br />
You can go further with it, too. For instance, if I want to change the first part of the filename, since they’re all named IMG_0123.JPG</p>
<p>cd ~/photos/icanhaslinux<br />
rename &#8216;s/^IMG/icanhaslinux/&#8217; *<br />
rename &#8216;s/JPG$/jpg&#8217; *</p>
<p>It accepts very sed-like regexp behavior.</p>
<p>Anyway, that&#8217;s all for now!<br />
-LightningCrash</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: alex</title>
		<link>http://polishlinux.org/console/regular-expressions-and-search-patterns/#comment-59572</link>
		<dc:creator>alex</dc:creator>
		<pubDate>Mon, 24 Sep 2007 13:17:16 +0000</pubDate>
		<guid isPermaLink="false">http://polishlinux.org/console/regular-expressions-and-search-patterns/#comment-59572</guid>
		<description><![CDATA[My current fav&#039; is &lt;em&gt;locate&lt;/em&gt; which also has the regular expression option for the command line (-e without checking). I find it swifter and easier than find (which I find much more complex to use and as I don&#039;t often use it always have to look things up).]]></description>
		<content:encoded><![CDATA[<p>My current fav&#8217; is <em>locate</em> which also has the regular expression option for the command line (-e without checking). I find it swifter and easier than find (which I find much more complex to use and as I don&#8217;t often use it always have to look things up).</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: michuk</title>
		<link>http://polishlinux.org/console/regular-expressions-and-search-patterns/#comment-59511</link>
		<dc:creator>michuk</dc:creator>
		<pubDate>Mon, 24 Sep 2007 09:54:32 +0000</pubDate>
		<guid isPermaLink="false">http://polishlinux.org/console/regular-expressions-and-search-patterns/#comment-59511</guid>
		<description><![CDATA[Thanks. Corrected!]]></description>
		<content:encoded><![CDATA[<p>Thanks. Corrected!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Geoff</title>
		<link>http://polishlinux.org/console/regular-expressions-and-search-patterns/#comment-59395</link>
		<dc:creator>Geoff</dc:creator>
		<pubDate>Mon, 24 Sep 2007 01:54:20 +0000</pubDate>
		<guid isPermaLink="false">http://polishlinux.org/console/regular-expressions-and-search-patterns/#comment-59395</guid>
		<description><![CDATA[An excellent article. Two typos, though: &#039;proceeding&#039; is used twice, when &#039;preceding&#039; is really meant. &#039;proceeding&#039; would mean that the characters are underway, or going somewhere, which is not the intended sense.]]></description>
		<content:encoded><![CDATA[<p>An excellent article. Two typos, though: &#8216;proceeding&#8217; is used twice, when &#8216;preceding&#8217; is really meant. &#8216;proceeding&#8217; would mean that the characters are underway, or going somewhere, which is not the intended sense.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
