<?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: 5 Practical Examples To Delete / Remove Directory in Linux</title>
	<atom:link href="http://www.thegeekstuff.com/2009/06/how-to-linux-delete-directory-using-rmdir-rm-command/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.thegeekstuff.com/2009/06/how-to-linux-delete-directory-using-rmdir-rm-command/</link>
	<description>Guides, HowTos and Tips for Technology Geeks</description>
	<lastBuildDate>Mon, 15 Mar 2010 16:15:33 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: nardi</title>
		<link>http://www.thegeekstuff.com/2009/06/how-to-linux-delete-directory-using-rmdir-rm-command/comment-page-1/#comment-38380</link>
		<dc:creator>nardi</dc:creator>
		<pubDate>Mon, 08 Mar 2010 09:04:56 +0000</pubDate>
		<guid isPermaLink="false">http://www.thegeekstuff.com/?p=551#comment-38380</guid>
		<description>@Richard
you have to backslash the space. 

$ cd Work\ Permit
$ rm -r Work\ Permit

quoting should work too. 
$ cd &quot;Work Permit&quot;
$ rm -r &quot;Work Permit&quot;</description>
		<content:encoded><![CDATA[<p>@Richard<br />
you have to backslash the space. </p>
<p>$ cd Work\ Permit<br />
$ rm -r Work\ Permit</p>
<p>quoting should work too.<br />
$ cd &#8220;Work Permit&#8221;<br />
$ rm -r &#8220;Work Permit&#8221;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Richard</title>
		<link>http://www.thegeekstuff.com/2009/06/how-to-linux-delete-directory-using-rmdir-rm-command/comment-page-1/#comment-38221</link>
		<dc:creator>Richard</dc:creator>
		<pubDate>Sun, 07 Mar 2010 12:50:32 +0000</pubDate>
		<guid isPermaLink="false">http://www.thegeekstuff.com/?p=551#comment-38221</guid>
		<description>Hello,

I hope someone can give me an answer to a question I have now for a few day&#039;s...
: How can I Remove a complete Directory with sub folders and files  when a Directory has a name with a space in between, some Directory called &quot;Work Permit&quot; to remove in my home Directory?  Every time I get the message that it&#039;s not recognized, and I also cannot CD to that Directory...

I hope someone can help me.... HELP!!!</description>
		<content:encoded><![CDATA[<p>Hello,</p>
<p>I hope someone can give me an answer to a question I have now for a few day&#8217;s&#8230;<br />
: How can I Remove a complete Directory with sub folders and files  when a Directory has a name with a space in between, some Directory called &#8220;Work Permit&#8221; to remove in my home Directory?  Every time I get the message that it&#8217;s not recognized, and I also cannot CD to that Directory&#8230;</p>
<p>I hope someone can help me&#8230;. HELP!!!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: aryan</title>
		<link>http://www.thegeekstuff.com/2009/06/how-to-linux-delete-directory-using-rmdir-rm-command/comment-page-1/#comment-30361</link>
		<dc:creator>aryan</dc:creator>
		<pubDate>Thu, 21 Jan 2010 01:47:10 +0000</pubDate>
		<guid isPermaLink="false">http://www.thegeekstuff.com/?p=551#comment-30361</guid>
		<description>@Hydrargentium
@nardi

Yeah it works...rm -r aryan/*
thats gr8 to have your replies....</description>
		<content:encoded><![CDATA[<p>@Hydrargentium<br />
@nardi</p>
<p>Yeah it works&#8230;rm -r aryan/*<br />
thats gr8 to have your replies&#8230;.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: nardi</title>
		<link>http://www.thegeekstuff.com/2009/06/how-to-linux-delete-directory-using-rmdir-rm-command/comment-page-1/#comment-30357</link>
		<dc:creator>nardi</dc:creator>
		<pubDate>Thu, 21 Jan 2010 00:55:52 +0000</pubDate>
		<guid isPermaLink="false">http://www.thegeekstuff.com/?p=551#comment-30357</guid>
		<description>@aryan
@Hydrargentium
There is one more thing. In case you have some hidden files in that directory (files beginning with &#039;.&#039;) they will be ignored while expanding the * wildcart. 

WARNING: read whole sentence before trying to remove anything. =)
In fact using &quot;aryan/.*&quot; would help nither, because it also contains the &quot;aryan/..&quot; (try ls aryan/.*) which is your actual directory. You could ommit it by using &quot;aryan/.[^.]*&quot; but it seems way too compicated to me. 

So in case you want to remove content of directory &quot;aryan&quot; including hidden files, I prefer to use rm -r `ls -A aryan`

OK. I tried it now with rm.... To correct myself you can simpy use:   rm -r aryan/.* ayran/*
because rm will just complain about it like this: 
rm: cannot remove `.&#039; directory `aryan/.&#039;
rm: cannot remove `..&#039; directory `aryan/..&#039;
but it will correctly erase all the content and nothing else. As I hate such errors i&#039;d still use ls =)

Know it&#039;s not too helpfull. Just FYI in case you use hidden files.</description>
		<content:encoded><![CDATA[<p>@aryan<br />
@Hydrargentium<br />
There is one more thing. In case you have some hidden files in that directory (files beginning with &#8216;.&#8217;) they will be ignored while expanding the * wildcart. </p>
<p>WARNING: read whole sentence before trying to remove anything. =)<br />
In fact using &#8220;aryan/.*&#8221; would help nither, because it also contains the &#8220;aryan/..&#8221; (try ls aryan/.*) which is your actual directory. You could ommit it by using &#8220;aryan/.[^.]*&#8221; but it seems way too compicated to me. </p>
<p>So in case you want to remove content of directory &#8220;aryan&#8221; including hidden files, I prefer to use rm -r `ls -A aryan`</p>
<p>OK. I tried it now with rm&#8230;. To correct myself you can simpy use:   rm -r aryan/.* ayran/*<br />
because rm will just complain about it like this:<br />
rm: cannot remove `.&#8217; directory `aryan/.&#8217;<br />
rm: cannot remove `..&#8217; directory `aryan/..&#8217;<br />
but it will correctly erase all the content and nothing else. As I hate such errors i&#8217;d still use ls =)</p>
<p>Know it&#8217;s not too helpfull. Just FYI in case you use hidden files.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Hydrargentium</title>
		<link>http://www.thegeekstuff.com/2009/06/how-to-linux-delete-directory-using-rmdir-rm-command/comment-page-1/#comment-30325</link>
		<dc:creator>Hydrargentium</dc:creator>
		<pubDate>Wed, 20 Jan 2010 16:37:48 +0000</pubDate>
		<guid isPermaLink="false">http://www.thegeekstuff.com/?p=551#comment-30325</guid>
		<description>To delete everything in a directory, WITHOUT deleting the directory itself (in answer to the previous post):

rm -r aryan/*

By using the the &quot;/*&quot; at the end, this path expands to &quot;everything in the aryan directory&quot;. Notice that this does not include the aryan directory itself. Therefore, the contents are deleted, but the directory itself is left intact.

Hg</description>
		<content:encoded><![CDATA[<p>To delete everything in a directory, WITHOUT deleting the directory itself (in answer to the previous post):</p>
<p>rm -r aryan/*</p>
<p>By using the the &#8220;/*&#8221; at the end, this path expands to &#8220;everything in the aryan directory&#8221;. Notice that this does not include the aryan directory itself. Therefore, the contents are deleted, but the directory itself is left intact.</p>
<p>Hg</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: aryan</title>
		<link>http://www.thegeekstuff.com/2009/06/how-to-linux-delete-directory-using-rmdir-rm-command/comment-page-1/#comment-18329</link>
		<dc:creator>aryan</dc:creator>
		<pubDate>Fri, 02 Oct 2009 06:22:21 +0000</pubDate>
		<guid isPermaLink="false">http://www.thegeekstuff.com/?p=551#comment-18329</guid>
		<description>Hi
Actually I want to delete all the files and subdirectories in the directory(say &#039;aryan&#039;) without deleting the directory(&#039;aryan&#039;) i.e. i want to empty the directory.</description>
		<content:encoded><![CDATA[<p>Hi<br />
Actually I want to delete all the files and subdirectories in the directory(say &#8216;aryan&#8217;) without deleting the directory(&#8216;aryan&#8217;) i.e. i want to empty the directory.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: pravin</title>
		<link>http://www.thegeekstuff.com/2009/06/how-to-linux-delete-directory-using-rmdir-rm-command/comment-page-1/#comment-13859</link>
		<dc:creator>pravin</dc:creator>
		<pubDate>Fri, 07 Aug 2009 06:13:07 +0000</pubDate>
		<guid isPermaLink="false">http://www.thegeekstuff.com/?p=551#comment-13859</guid>
		<description>Hello all
i am having trouble in deleting a directory in ubuntu. the directory permission &amp; ownership some how changed to like this ???? ??????  so i am not able to remove to this directory can any body help me.

Thanks, 
Praivn Bari</description>
		<content:encoded><![CDATA[<p>Hello all<br />
i am having trouble in deleting a directory in ubuntu. the directory permission &amp; ownership some how changed to like this ???? ??????  so i am not able to remove to this directory can any body help me.</p>
<p>Thanks,<br />
Praivn Bari</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ramesh Natarajan</title>
		<link>http://www.thegeekstuff.com/2009/06/how-to-linux-delete-directory-using-rmdir-rm-command/comment-page-1/#comment-12437</link>
		<dc:creator>Ramesh Natarajan</dc:creator>
		<pubDate>Thu, 09 Jul 2009 05:05:04 +0000</pubDate>
		<guid isPermaLink="false">http://www.thegeekstuff.com/?p=551#comment-12437</guid>
		<description>&lt;strong&gt;@Nardi,&lt;/strong&gt; Thanks for explaining in detail about how to ignore an alias command. You rock!

&lt;strong&gt;@Ronald,&lt;/strong&gt; Thanks for starting the discussion on this topic to make it very meaningful and useful to others who are reading this.</description>
		<content:encoded><![CDATA[<p><strong>@Nardi,</strong> Thanks for explaining in detail about how to ignore an alias command. You rock!</p>
<p><strong>@Ronald,</strong> Thanks for starting the discussion on this topic to make it very meaningful and useful to others who are reading this.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ah great, so the \ overrules the alias, makes sense</title>
		<link>http://www.thegeekstuff.com/2009/06/how-to-linux-delete-directory-using-rmdir-rm-command/comment-page-1/#comment-12318</link>
		<dc:creator>Ah great, so the \ overrules the alias, makes sense</dc:creator>
		<pubDate>Mon, 06 Jul 2009 08:02:29 +0000</pubDate>
		<guid isPermaLink="false">http://www.thegeekstuff.com/?p=551#comment-12318</guid>
		<description>Ah great, so the \ overrules the alias, makes sense 
Thanks for the example!Ah great, so the \ overrules the alias, makes sense 
Thanks for the example!</description>
		<content:encoded><![CDATA[<p>Ah great, so the \ overrules the alias, makes sense<br />
Thanks for the example!Ah great, so the \ overrules the alias, makes sense<br />
Thanks for the example!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ronald</title>
		<link>http://www.thegeekstuff.com/2009/06/how-to-linux-delete-directory-using-rmdir-rm-command/comment-page-1/#comment-12062</link>
		<dc:creator>Ronald</dc:creator>
		<pubDate>Mon, 29 Jun 2009 09:21:21 +0000</pubDate>
		<guid isPermaLink="false">http://www.thegeekstuff.com/?p=551#comment-12062</guid>
		<description>Ah great, so the \ overrules the alias, makes sense :D
Thanks for the example!</description>
		<content:encoded><![CDATA[<p>Ah great, so the \ overrules the alias, makes sense <img src='http://www.thegeekstuff.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /><br />
Thanks for the example!</p>
]]></content:encoded>
	</item>
</channel>
</rss>
