Delete Files

Problem:

-bash: /bin/rm: Argument list too long

Solution:

Delete all files:

for i in *; do rm "$i"; done

Delete special files:

for i in *.jpg; do rm "$i"; done

delete by first letter:

for i in $( echo {a..z} ); do rm $i*.jpg ; done
 
Nach oben
delete.txt · Zuletzt geändert: 2024/02/29 13:36 von 127.0.0.1
chimeric.de = chi`s home Creative Commons License Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0
DFmW2CEce3htPL1uNQuHUVu4Tk6WXigFQp   Dogecoin Donations Accepted Here    DFmW2CEce3htPL1uNQuHUVu4Tk6WXigFQp  DFmW2CEce3htPL1uNQuHUVu4Tk6WXigFQp