This line renames all files in a directory to remove the front of their names up to and including the first underscore character.
e.g.:
1242_file.txt
1209_another_file.txt
99_red balloons.wav
~becomes~
file.txt
another_file.txt
red balloons.wav
for i in *; do mv "$i" "`echo "$i" | sed 's/^[^_]*_//'`"; done
No comments:
Post a Comment