Delete x files from folder in a for i loop
Delete x files from folder in a for i loop
Recently I tried to remove a big bunch of files from one of my raspberry pies where ffmpeg had swamped my SD-card with too many capture images. So I had to delete x files from folder.
I just tried:
rm -rf *.jpg
But that gave me an “unable to execute /bin/rm: Argument list too long” error message.
So I needed a bash script that helps me to delete x files from folder. That’s why I wrote this tiny…
View On WordPress








