<?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: HowTo: Debug a Shell Script Under Linux or UNIX</title> <atom:link href="http://www.cyberciti.biz/tips/debugging-shell-script.html/feed" rel="self" type="application/rss+xml" /><link>http://www.cyberciti.biz/tips/debugging-shell-script.html</link> <description>This is a Linux sys admin journal by Vivek about sys admin work, Linux tips &#38; tricks, hacks, news and more.</description> <lastBuildDate>Fri, 10 Feb 2012 20:37:43 +0000</lastBuildDate> <sy:updatePeriod>hourly</sy:updatePeriod> <sy:updateFrequency>1</sy:updateFrequency> <generator>http://wordpress.org/?v=3.3.1</generator> <item><title>By: achyut</title><link>http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-172307</link> <dc:creator>achyut</dc:creator> <pubDate>Wed, 06 Jul 2011 12:27:21 +0000</pubDate> <guid
isPermaLink="false">http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-172307</guid> <description>Excellent Topic</description> <content:encoded><![CDATA[<p>Excellent Topic</p> ]]></content:encoded> </item> <item><title>By: SS Senthil Kumar</title><link>http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-170277</link> <dc:creator>SS Senthil Kumar</dc:creator> <pubDate>Tue, 22 Mar 2011 17:03:37 +0000</pubDate> <guid
isPermaLink="false">http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-170277</guid> <description>I am going to move from HP-Unix to Redhat Linux server. I have many bash shell programs in HP-Unix. Will they need change when i move to Linux (RHEL)? Kindly advice.</description> <content:encoded><![CDATA[<p>I am going to move from HP-Unix to Redhat Linux server. I have many bash shell programs in HP-Unix. Will they need change when i move to Linux (RHEL)? Kindly advice.</p> ]]></content:encoded> </item> <item><title>By: Vivek Gite</title><link>http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-156097</link> <dc:creator>Vivek Gite</dc:creator> <pubDate>Thu, 20 May 2010 20:17:00 +0000</pubDate> <guid
isPermaLink="false">http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-156097</guid> <description>Philippe,
Thanks for your feedback. The post has been updated.</description> <content:encoded><![CDATA[<p>Philippe,</p><p>Thanks for your feedback. The post has been updated.</p> ]]></content:encoded> </item> <item><title>By: Philippe Petrinko</title><link>http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-156083</link> <dc:creator>Philippe Petrinko</dc:creator> <pubDate>Wed, 19 May 2010 17:06:40 +0000</pubDate> <guid
isPermaLink="false">http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-156083</guid> <description>Hi Vivek,
if this is not required, would you consider cleaning code - mainly because that may confuse novice programmers and may induce bugs ... Thanks in advance! Nice topic, one more!</description> <content:encoded><![CDATA[<p>Hi Vivek,<br
/> if this is not required, would you consider cleaning code &#8211; mainly because that may confuse novice programmers and may induce bugs &#8230; Thanks in advance! Nice topic, one more!</p> ]]></content:encoded> </item> <item><title>By: Vivek Gite</title><link>http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-153180</link> <dc:creator>Vivek Gite</dc:creator> <pubDate>Thu, 28 Jan 2010 04:36:11 +0000</pubDate> <guid
isPermaLink="false">http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-153180</guid> <description>Yes, it is not required.</description> <content:encoded><![CDATA[<p>Yes, it is not required.</p> ]]></content:encoded> </item> <item><title>By: psc</title><link>http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-153171</link> <dc:creator>psc</dc:creator> <pubDate>Wed, 27 Jan 2010 22:01:20 +0000</pubDate> <guid
isPermaLink="false">http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-153171</guid> <description>[ &quot;$_DEBUG&quot; == &quot;on&quot; ] &amp;&amp;  $@ &#124;&#124; :
Why are you using last &#124;&#124; operator?</description> <content:encoded><![CDATA[<p>[ "$_DEBUG" == "on" ] &amp;&amp;  $@ || :</p><p>Why are you using last || operator?</p> ]]></content:encoded> </item> <item><title>By: dekkard</title><link>http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-152844</link> <dc:creator>dekkard</dc:creator> <pubDate>Mon, 11 Jan 2010 06:37:11 +0000</pubDate> <guid
isPermaLink="false">http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-152844</guid> <description>very nice, thanx</description> <content:encoded><![CDATA[<p>very nice, thanx</p> ]]></content:encoded> </item> <item><title>By: yura</title><link>http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-146465</link> <dc:creator>yura</dc:creator> <pubDate>Sat, 27 Dec 2008 20:52:02 +0000</pubDate> <guid
isPermaLink="false">http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-146465</guid> <description>http://bashdb.sourceforge.net/</description> <content:encoded><![CDATA[<p><a
href="http://bashdb.sourceforge.net/" rel="nofollow">http://bashdb.sourceforge.net/</a></p> ]]></content:encoded> </item> <item><title>By: mosjin</title><link>http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-143825</link> <dc:creator>mosjin</dc:creator> <pubDate>Tue, 20 May 2008 07:37:11 +0000</pubDate> <guid
isPermaLink="false">http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-143825</guid> <description>It&#039;s a good idea. Thanks!</description> <content:encoded><![CDATA[<p>It&#8217;s a good idea. Thanks!</p> ]]></content:encoded> </item> <item><title>By: thievm</title><link>http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-143714</link> <dc:creator>thievm</dc:creator> <pubDate>Thu, 08 May 2008 11:33:58 +0000</pubDate> <guid
isPermaLink="false">http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-143714</guid> <description>thanks,it is good idea</description> <content:encoded><![CDATA[<p>thanks,it is good idea</p> ]]></content:encoded> </item> <item><title>By: sartan</title><link>http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-142933</link> <dc:creator>sartan</dc:creator> <pubDate>Tue, 19 Feb 2008 00:59:42 +0000</pubDate> <guid
isPermaLink="false">http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-142933</guid> <description>I liked this debug method and implemented it in a simple script I wrote :) It really does make for much cleaner code than what I have been doing before. Thanks mate</description> <content:encoded><![CDATA[<p>I liked this debug method and implemented it in a simple script I wrote :) It really does make for much cleaner code than what I have been doing before. Thanks mate</p> ]]></content:encoded> </item> <item><title>By: nixcraft</title><link>http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-68223</link> <dc:creator>nixcraft</dc:creator> <pubDate>Thu, 01 Feb 2007 22:00:41 +0000</pubDate> <guid
isPermaLink="false">http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-68223</guid> <description>_ranger_,
Good idea however you may have to modify script little to check if _DEBUG is defined or not.
Appreciate  your post.</description> <content:encoded><![CDATA[<p>_ranger_,</p><p>Good idea however you may have to modify script little to check if _DEBUG is defined or not.</p><p>Appreciate  your post.</p> ]]></content:encoded> </item> <item><title>By: _ranger_</title><link>http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-67704</link> <dc:creator>_ranger_</dc:creator> <pubDate>Wed, 31 Jan 2007 15:30:57 +0000</pubDate> <guid
isPermaLink="false">http://www.cyberciti.biz/tips/debugging-shell-script.html#comment-67704</guid> <description>For running under &quot;set -x&quot; or &quot;set +x&quot;, why not just run it as:
bash -x ./script.sh
Also, instead of having _DEBUG in your script, just export it from your shell:
$ export _DEBUG=on
Now, you have to make absolutely no changes to enable or disable all debugging.</description> <content:encoded><![CDATA[<p>For running under &#8220;set -x&#8221; or &#8220;set +x&#8221;, why not just run it as:</p><p>bash -x ./script.sh</p><p>Also, instead of having _DEBUG in your script, just export it from your shell:</p><p>$ export _DEBUG=on</p><p>Now, you have to make absolutely no changes to enable or disable all debugging.</p> ]]></content:encoded> </item> </channel> </rss>
