You want to search for all the *.tar files in your home directory and wants to delete all at once. How will you do it?



You want to search for all the *.tar files in your home directory and wants to delete all at once. H..

Answer / Sohan Sagar Jha

To achieve this, use the command line with a combination of 'find', 'xargs' and 'rm'. Here's an example command: `find ~ -name '*.tar' -exec rm {} ;`. This command will search for all *.tar files in your home directory using find, then exec rm to delete them, and the ; tells it that the command is complete.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Linux General Interview Questions

Is linux the future of gaming?

1 Answers  


Is linux good for programming?

1 Answers  


What are the features of linux os over other operating systems etc?

1 Answers  


how can you configure dns caching server in linux operating system?

1 Answers   SwanSoft Technologies,


Is it possible to use shortcuts for a long pathname?

1 Answers  


How to jump to a particular line in a file using vim editor?

1 Answers  


What does gnu stand for?

1 Answers  


How do you sort the entries in a text file in ascending order?

1 Answers  


What does wget do in linux?

1 Answers  


Which are the shells used in linux?

1 Answers  


What is the main difference between yum & rpm?

1 Answers  


How to unzip a file in Linux?

1 Answers  


Categories