943,913 Members | Top Members by Rank

Ad:
May 25th, 2007
0

rm command

Expand Post »
Hi everyone,

Is there any option for rm to remove a directory with no prompts?Actually I know about rm -r but by this option I have to answer lots of questions...

Cheers,
Similar Threads
Reputation Points: 10
Solved Threads: 0
Newbie Poster
Toktam is offline Offline
5 posts
since May 2007
May 25th, 2007
0

Re: rm command

rm -rf i think?

that either does it, or deletes recursively. i cant remember. Google it. Be very careful if it is the latter
Last edited by jbennet; May 25th, 2007 at 8:03 am.
Moderator
Featured Poster
Reputation Points: 1784
Solved Threads: 574
Moderator
jbennet is online now Online
16,520 posts
since Apr 2005
May 25th, 2007
0

Re: rm command

Shell Scripting Syntax (Toggle Plain Text)
  1. man rm
  2.  
  3. -r is recursive (including the directories)
  4. -f force (don't ask)
  5. -i interactive (ask before deleting)
  6.  

Chances are, somewhere in the profile, whether in your shell or in /etc/profile is an alias that changes rm to rm -i.
Moderator
Reputation Points: 1471
Solved Threads: 490
Industrious Poster
masijade is offline Offline
4,043 posts
since Feb 2006
May 25th, 2007
0

Re: rm command

...
Last edited by jbennet; May 25th, 2007 at 11:07 am.
Moderator
Featured Poster
Reputation Points: 1784
Solved Threads: 574
Moderator
jbennet is online now Online
16,520 posts
since Apr 2005
May 25th, 2007
0

Re: rm command

...
Moderator
Reputation Points: 1471
Solved Threads: 490
Industrious Poster
masijade is offline Offline
4,043 posts
since Feb 2006
May 26th, 2007
0

Re: rm command

Yes I use rm -rf for deleting folders and sub folders recursively without prompt.
Team Colleague
Reputation Points: 45
Solved Threads: 56
Unauthenticated Liar
nanosani is offline Offline
1,767 posts
since Jul 2004
Jun 19th, 2007
0

Re: rm command

rm -f filename

-f don't prompt for confirmation

Hope this will solve your query
Reputation Points: 10
Solved Threads: 1
Newbie Poster
vrgurav is offline Offline
11 posts
since Jun 2007
Jun 19th, 2007
0

Re: rm command

rm -f filename

-f dont prompt for confirmation

Hope this will solve your query
Reputation Points: 10
Solved Threads: 1
Newbie Poster
vrgurav is offline Offline
11 posts
since Jun 2007

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in Shell Scripting Forum Timeline: KSH Passing parameters that start with $
Next Thread in Shell Scripting Forum Timeline: grep '^[a-zA-Z]'





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC