[Klug-general] genisoimage and files truncating.

sharon kimble boudiccas at talktalk.net
Mon Apr 30 20:58:39 UTC 2012


On Monday 30 April 2012 19:30:44 James Morris wrote:
> On 30 April 2012 18:50, sharon kimble <boudiccas at talktalk.net> wrote:
> > i am using genisoimage on this folder ...../home/boztu/Music/Irish Celtic
> > Music Collection Version 2 .... which contains 2976 mp3s, but it is
> > truncating the file names after the first word of their title. It
> > appears to be doing this at the first space that it encounters, so I'm
> > hoping someone can help me by suggesting a script that I can run that
> > will remove all spaces in the file names, before .mp3, to enable
> > genisoimage to run properly. The iso it creates is 18.9gbs in size and I
> > then run split to make it into 4gb sized files to be burnt to dvds.
> 
> take the code between the two cut lines:

Thanks James, this worked beautifully once i'd tried it out but still got to 
use split on it but i'm not envisaging any problems with it.You will 
appropriate acknowledgment in my blog :)

Thanks again
Sharon. 

> 
>  ----------8<------------------
> #!/bin/bash
> 
> find $1 -type f \(  -name '*.mp3'    \
>                 -o -name '*.MP3'    \) |
> while IFS= read -r NAME;
> do
> DEST=`echo "$NAME" | tr ' ' '_'`
> echo mv -v "${NAME}" "${DEST}"
> done
>  ----------8<------------------
> 
> and place into a file named ren_mp3s, and then to make it executable:
> 
> chmod +x ren_mp3s
> 
> and then do a test run of the script (it needs modification to do
> anything other than a test run):
> 
> ./ren_mp3s dir_containing_mp3s
> 
> make sure the output looks correct and then remove the echo command
> from before the mv command.
> 
> hope that helps
> 
> james.
> 
> > Can you help me please?

-- 
A taste of linux = http://www.sharons.org.uk/taste/index.html
efever = http://www.efever.blogspot.com/
efever = http://sharon04.livejournal.com/
Debian 6,0.4, Gnome 1:2.30+7, LibreOffice 3.5.2
Registered Linux user 334501 



More information about the Kent mailing list