View Single Post
Old Oct 30th, 2007, 10:07 PM   #1
acwbrat
Newbie
 
Join Date: Oct 2007
Posts: 17
Rep Power: 0 acwbrat is on a distinguished road
Lightbulb Bash File Rename and Deletion

I have written a file rename , however my code was suppose to check the input and output of the particular files being held. Also, I have written a second code that deletes the files that haven't been used in a while on a given directory. However, I thought my codes but I would like to know where I have messed up. Inquiring minds would like to know. Thanks!


#!/bin/bash

files=$(ls -1 | grep .mp3)

for x in $files
do
mv $x band_song$x
done
.....................
#!/bin/bash
for X in *.html
        do
                rm "$X";
        done
acwbrat is offline   Reply With Quote