hendrik on 16 Jan, 2018 05:52 PM
apologies, I've never reacted to this. I noticed and the request makes a lot of sense.
While coding a full blown inspection to do this takes a little bit more effort, a simple beaTlet is a piece of cake. I did and the result is attached.
on 27 Jan, 2018 12:56 AM
Tested it on a quite large library, worked fine and fast too, thank you. There was no clear indication what tracks and fields have been changed, but the Modification time could be used to sort by and see what comes on top.
Also thanks for pointing me to the plugin API, I may play with it later and do something in Python, seems clear and easy enough to me.
I'd love to do something similar with "smart" quotes, which get added when importing metadata from MusicBrainz in another app, for example. It makes a difference in searching and duplicate detection since the "smart" punctuation marks are not the same as the "plain" one, the title/filename whatever don't match and are therefore not duplicates.
The same song could live in a directory twice, once with smart and once with plain quotes, and most duplicate detection apps or sync apps wouldn't realize it's the same song. Really annoying!
Apologies, hendrik. Yes, curly quotes. I didn't mean to imply the straight
quotes aren't as intelligent as the curly ones.
I think I pulled that term from the distant past when word processor
vendors were proud of themselves and excited being able to "intelligently"
know which curly quote to replace for their normal brethren.
Also in this hypothetical character replacement is backtick ` (accent
grave) replaced with an apostrophe.
I actually think these characters, leading, trailing, and extra whitespace
(two or more consecutive spaces) wound be very much at home in the
Inspection section. They're every bit as annoying as improper /
inconsistent capitalization and spelling.
hendrik on 05 Apr, 2020 07:33 AM
Ha! No worries. Just wanted to make sure I understand correctly.
Of course, one could write a beaTlet for this and I am happy to support you, should you be interested in this endeavor. But in many years of running beaTunes, no one has requested an inspection for curly or fancy quotes before (TextEdit indeed has this mechanism for "smart" quotes). This is not to say that it is in invalid request, I just think you may be better served by simply using Find & Replace with regular expressions ("regex"). To open the Find & Replace panel, use Edit -> Find.
Now, do you want to remove all quotes or do you want to normalize them to all plain quotes?
To remove you could simply use this regular expression, which means that the Regex checkbox needs to be checked (see attached screenshot):
This would match textfields in the visible list starting with a curly quote and ending with a regular quote.
You can easily modify this to normalize, simply by replaying all fancy quotes (or any other character):
For this you don't need the Regex checkbox to be on.
If you want to apply this to your library, first select your Music list and then open the Find & Replace panel. You may also filter for curly quotes before you find and replace, to trim down the list of candidates.
OMG. You know, I've never even opened the Find function in beaTunes. I'm usually quite fond of Find and Replace. It always looked like a vestigial OS X/macOS menu that can never be really gotten rid of but isn't always of much use. I just assumed the Filter field was the search/Find capability like iTunes, I suppose.
Actually, I could probably use this awesome "new" find capability to corral the tracks with the "offending" punctuation and create a playlist from that.
I do most track editing from Yate. I can script changes plus keep a log of the changes in the event I decided something went awry. Definitely something to play with later!
I admit the Find/replace feature is really powerful. It wasn't quite what I was expecting, though. I was expecting more of a Filter effect or at least a counter with x of y occurrences. If the playlist is of any substantial size, it's really difficult to see how many instances are affected and to verify the resulting action is appropriate.
Also, if there's something that significant in the metadata that I'm doing a Find, there's a good chance the metadata isn't as clean as I'd like and there are most likely additional "issues" (not always, but a good chance). (It did give me the idea of creating a Smart Playlist in iTunes/Music for leading/trailing spaces, and that's how I came to the generalization that there's additional metadata that "needed" changing.)
So...I can't add all the "selected" files to a new playlist, for example, because the matching files aren't selected.
If even a fraction of that Find capability could be added to the Filter box/feature, that would be amazingly powerful. I don't know of another tool that could do a regex find on an entire existing library. JRiver and Yate are the closest that immediately come to mind, but they would both require creating a new library/database first.
EDIT: OK, so I didn't give the Filter box enough time to populate. The curly quotes example does work in Filter. Multiple spaces does not. There isn't a significant spike in CPU or a UI change, so I assumed it wasn't found.
The regex feature and the overlay for replacement are definitely cool.