View Full Version : How do I find and remove all instances of *small.jpg in my Music directory?

2021-09-06, 18:27
Hello, I am pretty new to Linux, but am currently running it as my main OS, alongside Windows 11.

I have just added all my music to the ~/Music directory so lots of sub directories under that for different artists etc.

All these album files have album cover jpg files but have them in *large.jpg and *small.jpg - I don't really see the point of both.

I would like to know if there is a command line instruction using grep or something that will search all the ~/Music sub directories for all *small.jpg files and then allow me to delete them all in one go... Or something like that?


2021-11-26, 19:32
Since you know about grep, then you should be looking at the pipe command and the ?rm? command. Reading the man pages, or a search for ?remove grepped files? should get you to the right path.