View Single Post
Old Oct 30th, 2007, 11:27 PM   #2
Sane
Programming Guru
 
Sane's Avatar
 
Join Date: Apr 2005
Posts: 1,799
Rep Power: 5 Sane will become famous soon enough
Re: Bash File Rename and Deletion

I haven't ever seen a single line of Bash before, but since you PM'd me, I'll give it a shot.

If you are trying to rename all of the mp3s to have the prefix "band_song", then I would have to guess this. This is a total shot in the dark though...

#!/bin/bash

for x in *.mp3
        do
                mv "$x" "band_song$x";
        done

Unless your script already worked, and you were trying to "check the input". Which you'll need to be more specific about.
Sane is offline   Reply With Quote