Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to delete a directory?

Status
Not open for further replies.

coca11

Programmer
Mar 20, 2002
7
CA
I am trying to clean up a directory if I do

rm -r -f <name of dir>
I still get prompted for every file. I have to delte hundreds of files is there a fast way of doing that?
 
Hi,
As Tony said, you probably have an alias set for rm, check your login shell.
For example, if you're using korn shell go to your home directory and edit .kshrc and look for the line alias rm=.... you will probably see rm='rm -i' where the -i(interactive) is set for security reason, in order to prevent you from deleting files without asking.

N.B.: have a copy of your .kshrc before editing.

Regards,
Christian
 
You can also &quot;unalias&quot; anything you have set an alias for by typing:

unalias <name_of_alias>

for example:

unalias rm

would remove the alias that you have set for rm. But like ChristianS mentioned, it's set for security reasons so you have to be careful if you want to unalias the rm alias.

Regards,
Chuck

chuck.spilman@nokia.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top