Results 1 to 3 of 3
Hi there
I am currently trying to maintain my music collection, and have come across a problem. The main collection is saved as high quality MP3's and FLAC and then ...
- 10-29-2011 #1Just Joined!
- Join Date
- Mar 2007
- Posts
- 93
Program to rename special characters
Hi there
I am currently trying to maintain my music collection, and have come across a problem. The main collection is saved as high quality MP3's and FLAC and then converted into small mp3s for my portable player.
The conversion is done with SoundKonverter 1.2 which has an option to convert all special characters to _ or keep them as they are. It generates file names and folders based on ID3 tags rather than original file names. I then use diff and grip to find any files that converted with the wrong name, or into the wrong folder etc.
The conversion is done with SoundKonverter 1.2 which has an option to convert all special characters to _
However, I would like some special characters to become different things to _
For example, I want to use a mapping similar to this
/|\ and : become -
< and > become ( and )
” becomes ' (or is it the other way around)
* becomes _
? is removed
I have seen a few basic scripts online that can remove special characters but none that offer different mappings like this, and I do not know how to edit them to do what I need. Is there a program that could do this? Its important that any method can see recursive or subdirectories as my music is stored as /music/filetype/artist/album/SONGS.XXX
Currently running Suse11.4 with KDE4.6
Any help appreciated
Jonny
- 11-01-2011 #2
Let me introduce you to my friend sed and the magical world of regular expressions. Sed - An Introduction and Tutorial
linux user # 503963
- 11-02-2011 #3Linux Guru
- Join Date
- May 2011
- Posts
- 1,844
just a note - watch out for those (, ), and " characters. They will probably have to be escaped. In fact, if I were you, I'd dump quotes in file names altogether.


Reply With Quote