<?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"
	>
<channel>
	<title>Comments on: Nifty commands</title>
	<atom:link href="http://www.sourceguru.net/archives/105/feed" rel="self" type="application/rss+xml" />
	<link>http://www.sourceguru.net/archives/105</link>
	<description></description>
	<pubDate>Sat, 06 Sep 2008 18:42:55 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6</generator>
		<item>
		<title>By: Kai Grossjohann</title>
		<link>http://www.sourceguru.net/archives/105#comment-15628</link>
		<dc:creator>Kai Grossjohann</dc:creator>
		<pubDate>Wed, 09 Jan 2008 15:49:16 +0000</pubDate>
		<guid isPermaLink="false">http://www.sourceguru.net/archives/105#comment-15628</guid>
		<description>I suggest not to use killall; if you ever use it on a Solaris box, you'll be surprised.

pkill appears to be more portable.</description>
		<content:encoded><![CDATA[<p>I suggest not to use killall; if you ever use it on a Solaris box, you&#8217;ll be surprised.</p>
<p>pkill appears to be more portable.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Enver ALTIN</title>
		<link>http://www.sourceguru.net/archives/105#comment-15580</link>
		<dc:creator>Enver ALTIN</dc:creator>
		<pubDate>Sat, 05 Jan 2008 19:48:43 +0000</pubDate>
		<guid isPermaLink="false">http://www.sourceguru.net/archives/105#comment-15580</guid>
		<description>You can use `evolution --force-shutdown` for a graceful one.

-HTH</description>
		<content:encoded><![CDATA[<p>You can use `evolution &#8211;force-shutdown` for a graceful one.</p>
<p>-HTH</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: joi</title>
		<link>http://www.sourceguru.net/archives/105#comment-15550</link>
		<dc:creator>joi</dc:creator>
		<pubDate>Thu, 03 Jan 2008 18:39:52 +0000</pubDate>
		<guid isPermaLink="false">http://www.sourceguru.net/archives/105#comment-15550</guid>
		<description>http://speculation.org/garrick/kill-9.html</description>
		<content:encoded><![CDATA[<p><a href="http://speculation.org/garrick/kill-9.html" rel="nofollow">http://speculation.org/garrick/kill-9.html</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: litb</title>
		<link>http://www.sourceguru.net/archives/105#comment-15548</link>
		<dc:creator>litb</dc:creator>
		<pubDate>Thu, 03 Jan 2008 17:47:47 +0000</pubDate>
		<guid isPermaLink="false">http://www.sourceguru.net/archives/105#comment-15548</guid>
		<description>my commands of choice:
# waits until the given processes (may be multiple pids) are not running anymore
# killall -w does this too, but it waits 1second at least.
# we don't want to wait so long o.O .
# NOTE: this doesn't work on a system which uses randomized PIDs . afaik
# linux tries to use PIDs which were not used before, so that is
# not a problem here.
function wait_for_pid() {
    # $@ means "$1" "$2" ... "$n" . ( all the args given to this function )
    while ( for i in $@; do [[ -d /proc/"$i" ]] &#38;&#38; return 0; done; return 1 ); do
        sleep 0.15s;
    done
}

i would be glad to know how this could be even made better!</description>
		<content:encoded><![CDATA[<p>my commands of choice:<br />
# waits until the given processes (may be multiple pids) are not running anymore<br />
# killall -w does this too, but it waits 1second at least.<br />
# we don&#8217;t want to wait so long o.O .<br />
# NOTE: this doesn&#8217;t work on a system which uses randomized PIDs . afaik<br />
# linux tries to use PIDs which were not used before, so that is<br />
# not a problem here.<br />
function wait_for_pid() {<br />
    # $@ means &#8220;$1&#8243; &#8220;$2&#8243; &#8230; &#8220;$n&#8221; . ( all the args given to this function )<br />
    while ( for i in $@; do [[ -d /proc/"$i" ]] &amp;&amp; return 0; done; return 1 ); do<br />
        sleep 0.15s;<br />
    done<br />
}</p>
<p>i would be glad to know how this could be even made better!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: The Linux Index &#187; Martin Meredith: Stand back, I know regular expressions</title>
		<link>http://www.sourceguru.net/archives/105#comment-15540</link>
		<dc:creator>The Linux Index &#187; Martin Meredith: Stand back, I know regular expressions</dc:creator>
		<pubDate>Thu, 03 Jan 2008 03:31:34 +0000</pubDate>
		<guid isPermaLink="false">http://www.sourceguru.net/archives/105#comment-15540</guid>
		<description>[...] after the last blog post, I was talking to Seveas and mentioned how I thought with all the nifty and useful commands coming [...]</description>
		<content:encoded><![CDATA[<p>[...] after the last blog post, I was talking to Seveas and mentioned how I thought with all the nifty and useful commands coming [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Zeth</title>
		<link>http://www.sourceguru.net/archives/105#comment-15537</link>
		<dc:creator>Zeth</dc:creator>
		<pubDate>Thu, 03 Jan 2008 01:35:32 +0000</pubDate>
		<guid isPermaLink="false">http://www.sourceguru.net/archives/105#comment-15537</guid>
		<description>I like to combine pdftotext with grep so I can search for keywords in a bunch of PDFs.
E.g. http://files.zeth.net/pdfgrep.txt</description>
		<content:encoded><![CDATA[<p>I like to combine pdftotext with grep so I can search for keywords in a bunch of PDFs.<br />
E.g. <a href="http://files.zeth.net/pdfgrep.txt" rel="nofollow">http://files.zeth.net/pdfgrep.txt</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Stand back, I know regular expressions at Source Guru</title>
		<link>http://www.sourceguru.net/archives/105#comment-15536</link>
		<dc:creator>Stand back, I know regular expressions at Source Guru</dc:creator>
		<pubDate>Thu, 03 Jan 2008 01:09:16 +0000</pubDate>
		<guid isPermaLink="false">http://www.sourceguru.net/archives/105#comment-15536</guid>
		<description>[...] Register          &#171; Nifty commands [...]</description>
		<content:encoded><![CDATA[<p>[...] Register          &laquo; Nifty commands [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Janne</title>
		<link>http://www.sourceguru.net/archives/105#comment-15535</link>
		<dc:creator>Janne</dc:creator>
		<pubDate>Thu, 03 Jan 2008 00:54:42 +0000</pubDate>
		<guid isPermaLink="false">http://www.sourceguru.net/archives/105#comment-15535</guid>
		<description>If you're a frequent camera user it might be instructive to check what focal length you're actually using the most. If you have "exiv2", an exif data reader/writer installed, you can easily do this:

exiv2 @(@(JPG)&#124;@(jpg)) &#124;sed -n -e "s/.*Focal length    : \([0-9.]*\).*/\1/p"&#124;sort -n&#124;uniq -c

You get the number of images per focal length, sorted by length. If you want a graphical representation it's trivial to cut and paste the output to gnumeric or some other spreadsheet and graph it.</description>
		<content:encoded><![CDATA[<p>If you&#8217;re a frequent camera user it might be instructive to check what focal length you&#8217;re actually using the most. If you have &#8220;exiv2&#8243;, an exif data reader/writer installed, you can easily do this:</p>
<p>exiv2 @(@(JPG)|@(jpg)) |sed -n -e &#8220;s/.*Focal length    : \([0-9.]*\).*/\1/p&#8221;|sort -n|uniq -c</p>
<p>You get the number of images per focal length, sorted by length. If you want a graphical representation it&#8217;s trivial to cut and paste the output to gnumeric or some other spreadsheet and graph it.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Michael R. Head</title>
		<link>http://www.sourceguru.net/archives/105#comment-15534</link>
		<dc:creator>Michael R. Head</dc:creator>
		<pubDate>Thu, 03 Jan 2008 00:48:19 +0000</pubDate>
		<guid isPermaLink="false">http://www.sourceguru.net/archives/105#comment-15534</guid>
		<description>yeah, evolution --force-shutdown appears in my Alt-F2 history. There used to be a killev script, but once the --force-shutdown option was added to the evo binary, they got rid of that one.</description>
		<content:encoded><![CDATA[<p>yeah, evolution &#8211;force-shutdown appears in my Alt-F2 history. There used to be a killev script, but once the &#8211;force-shutdown option was added to the evo binary, they got rid of that one.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jeff Schroeder</title>
		<link>http://www.sourceguru.net/archives/105#comment-15532</link>
		<dc:creator>Jeff Schroeder</dc:creator>
		<pubDate>Thu, 03 Jan 2008 00:35:48 +0000</pubDate>
		<guid isPermaLink="false">http://www.sourceguru.net/archives/105#comment-15532</guid>
		<description>wordpress mundged the ' in the awk command. make sure to use single quotes around the awk statement and it works like a charm:
jeff@omniscience:~$ lsof +c 15 &#124; awk '{print $1}' &#124; uniq -c &#124; sort -rn &#124; head
    325 epiphany
    283 liferea-bin
    250 thunderbird-bin
    248 python
    238 tomboy
    225 nautilus
    215 gnome-panel
    199 update-manager
    181 mixer_applet2
    177 update-notifier</description>
		<content:encoded><![CDATA[<p>wordpress mundged the &#8216; in the awk command. make sure to use single quotes around the awk statement and it works like a charm:<br />
jeff@omniscience:~$ lsof +c 15 | awk &#8216;{print $1}&#8217; | uniq -c | sort -rn | head<br />
    325 epiphany<br />
    283 liferea-bin<br />
    250 thunderbird-bin<br />
    248 python<br />
    238 tomboy<br />
    225 nautilus<br />
    215 gnome-panel<br />
    199 update-manager<br />
    181 mixer_applet2<br />
    177 update-notifier</p>
]]></content:encoded>
	</item>
</channel>
</rss>
