Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: foo_tradersfriend (Read 142477 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

foo_tradersfriend

Small suggestion - make it work with files that have 2 digits in the track number in the filename. Right now it only does this when the disc number is present. With etree files I don't think this is an issue, but the Further standard allows two-digit track numbers, and such files don't work.

foo_tradersfriend

Reply #1
Good to know there's actually somebody who uses this plugin.

Thanks for finding this bug. It's fixed now.

Perhaps I should say something about how the plugin guesses things:

Date: the plugin looks for YYYY-MM-DD or YY-MM-DD in the filename, where Y, M, and D are digits. I found this to work better than extracting the date from the text files, as dates occur in text files in a wide variety of formats.

Tracknumber and discnumber: taken from the filename. The filename must be in one of the following formats for this to work:
{artist}{date}{sth}d{discnumber}t{tracknumber}{sth else}
{artist}{date}{sth}d{discnumber}{tracknumber}{sth else}
{artist}{date}{sth}t{tracknumber}{sth else}
The discnumber is always only one digit, the tracknumber must be at least one digit. {artist} may be arbitrary text that does not contain a digit. {date} should be in YYYY-MM-DD or YY-MM-DD format. {sth} may be anything not looking like a discnumber or tracknumber. {sth else} may be arbitrary text.

The rest of the information is extracted from a text file as follows:

Artist and venue: These are extracted from the header, which should be in one of the following forms:

1)
artist: 1 line
date: 1 line
venue: 1 or more lines

2)
artist: 1 line
venue: 1 or more lines
date: 1 line

The plugin uses heuristics to recognize the line containing the date (the plugin can detect purely numerical formats as well as semi-textual formats like June 1, 2003). The first empty line terminates the header.

Title: Track titles are found by looking at all lines following the header. Lines describing tracks are have to start with X, tX, dytX, dYX, where X is the tracknumber and Y is the discnumber. This may be followed by '.', ')', '.)', ':', ' - ', or just whitespace.
If Y is not given, it is deduced as follows: If this is the first track found, Y is 1. If X is greater than the previously found tracknumber, Y is the same as there. Otherwise, Y is one more than the previous discnumber.

I hope this helps in case you run into problems with the plugin.

foo_tradersfriend

Reply #2
Could you add the option to change where it looks for a text file? It would like it to look in the same directory, not one level up.

foo_tradersfriend

Reply #3
Quote
Could you add the option to change where it looks for a text file? It would like it to look in the same directory, not one level up.

It should actually look in both directories. It then chooses the text file that shares the longest common prefix with your music file.
If the plugin uses the wrong text file, please tell me the name of (one of) the music files and of all text files in the same and in the parent directory.

foo_tradersfriend

Reply #4
I probably got the use of this plugin wrong. Is it for albums that has a text file for every track or albums that has a text file for the whole album? I guess the first, but I was hoping the second. It would be a nice addition when using the masstagger and you have a text file with all the correct info. Making copy and paste easier.

foo_tradersfriend

Reply #5
It is intended for albums/concerts with one text file for the whole album/concert. If you want to use it for single tracks with one text file each, you could set tracknumber (and discnumber, if present) to 1 before applying "guess values from text file". If the plugin can find the correct text file using the "longest common prefix" rule, then this should work as well.

foo_tradersfriend

Reply #6
Sorry, don't know what I did before, but it works now.

I have a problem when I try to edit a text file though.
A "\.\" directory is added like this:
D:\Music\Fugazi - 13 Songs\.\13 Songs.txt
When it should have been:
D:\Music\Fugazi - 13 Songs\13 Songs.txt

foo_tradersfriend

Reply #7
Quote
I have a problem when I try to edit a text file though.
A "\.\" directory is added like this:
D:\Music\Fugazi - 13 Songs\.\13 Songs.txt
When it should have been:
D:\Music\Fugazi - 13 Songs\13 Songs.txt

That's the same actually, so it shouldn't be a problem.
A riddle is a short sword attached to the next 2000 years.

foo_tradersfriend

Reply #8
Quote
I have a problem when I try to edit a text file though.
A "\.\" directory is added like this:
D:\Music\Fugazi - 13 Songs\.\13 Songs.txt
When it should have been:
D:\Music\Fugazi - 13 Songs\13 Songs.txt

I suppose you're using Win2k/XP? ssamadhi97 already mentioned this to me. Strangely enough, it works on Win98 with either Notepad or SciTE as default editor.

foo_tradersfriend

Reply #9
Quote
That's the same actually, so it shouldn't be a problem.

..note though that it seems to break direct file opening in programs - while using this kind of directory name works nicely in Windows' Common Dialogs.. 
A riddle is a short sword attached to the next 2000 years.

foo_tradersfriend

Reply #10
Yes I use WinXP.

I have a feature request that I could make use of, but I guess it's not really in the scope of this plugin in the first place:
An option in preferences, to set the file types to look for. A custom line like the one for "Album list" and "Core".

foo_tradersfriend

Reply #11
Quote
I have a feature request that I could make use of, but I guess it's not really in the scope of this plugin in the first place:
An option in preferences, to set the file types to look for. A custom line like the one for "Album list" and "Core".

I'm not sure what you mean here. Do you propose to have a format string that evaluates to the name of the text file to be used? Or restrict the effects of "guess values from text file" to certain types of music files?

foo_tradersfriend

Reply #12
Quote
Quote
I have a feature request that I could make use of, but I guess it's not really in the scope of this plugin in the first place:
An option in preferences, to set the file types to look for. A custom line like the one for "Album list" and "Core".

I'm not sure what you mean here. Do you propose to have a format string that evaluates to the name of the text file to be used? Or restrict the effects of "guess values from text file" to certain types of music files?

I'll try to explain it better.
For foobar's database you have the option to define the file types you want it to remember.
Restrict incoming file types to e.g. *.MPC;*.MP3;*.OGG;*.WMA

If you could add a feature like this, I would be able to open files like: *.log;*.nfo;*.m3u from within foobar to use with masstagger when renaming and fixing tags.

If you think this is way off target, just forget it. I like the foosion_pack anyway 

foo_tradersfriend

Reply #13
Quote
If you could add a feature like this, I would be able to open files like: *.log;*.nfo;*.m3u from within foobar to use with masstagger when renaming and fixing tags.

If you think this is way off target, just forget it. I like the foosion_pack anyway 

Ah, now I see whart you mean. Unfortunately, this plugin is geared towards text files describing concerts like on etree.org, which are in a semiformal format. So the parsing would fail for m3u files. I don't even know about the format used by the nfo and log files you mentioned.
Perhaps this would be a nice addition, but it is not what the plugin was intended for. So I won't add this, unless I get really, really bored. But don't count on that.

foo_tradersfriend

Reply #14
Important bug fix!

Please redownload the plugin! Previously, the data read from the text file was not translated to utf8 (I somehow missed that ).
Most of those text files use only ASCII chars, so this wasn't a problem. But then again, someone might use ASCII 150 instead of - (ASCII 45). The two look identical with monospaced fonts.
Non-utf8 values in tags make your playlist look jerky, and opening Album List will block foobar (at least it does on my Win98SE).

foo_tradersfriend

Reply #15
foo_tradersfriend 0.4.0

Update for SDK 0.7.1. The plugin now integrates into the official masstagger rather than replacing it. The direct access to single masstagger actions is missing from this version. I'll put that functionality into a separate plugin.

download link: plugin, source code

foo_tradersfriend

Reply #16
THANKS! This greatly improves my Foobar2000 experience. Some requests: give me a preview of what tradersfriend will parse from the file, and let me browse for the text file, if tradersfriend picks the wrong one.

This is great stuff. I saw this morning that 0.7.1 was out, got the special installer, got the latest foo_syfm and tradersfriend, and my life is very much improved.

foo_tradersfriend

Reply #17
This plugin remind me of something.
Generally I don't do any tagging thing, simply rename files into the format like
tracknum - title

I found this nice feather in another rename tool:
For example, there're 10 files here
file1
file2
...
file10

And there's a txt file, which content is 10 lines:
name1
name2
...
name10

Then the tool renames the 10 files according to the content of txt file, one file per line. It's very handy!

Can this plugin do this?

foo_tradersfriend

Reply #18
Quote
THANKS! This greatly improves my Foobar2000 experience. Some requests: give me a preview of what tradersfriend will parse from the file, and let me browse for the text file, if tradersfriend picks the wrong one.

Nice features, that I already thought about myself, so they might be implemented eventually.

foo_tradersfriend

Reply #19
@Raymond:
You can also do this with plain masstagger from 0.7.1 using the "Input data (one line per file)" tag editing action. Use "%temp%" as scheme and paste the contents of the text file in the text box titled "Input data...". After that, rename the files with masstagger; "Output filename format" should be set to "%temp%". Now you can now use masstagger again to get rid of the %temp% tag...

foo_tradersfriend can not simplify this process. In fact, it will most likely fail to parse the text files given the format you described. foo_tradersfriend relies on the presence of a header at the beginning of the file and on tracknumbers on each track's line.

foo_tradersfriend

Reply #20
Quote
@Raymond:
You can also do this with plain masstagger from 0.7.1 using the "Input data (one line per file)" tag editing action. Use "%temp%" as scheme and paste the contents of the text file in the text box titled "Input data...". After that, rename the files with masstagger; "Output filename format" should be set to "%temp%". Now you can now use masstagger again to get rid of the %temp% tag...

emm...it's not so convenient to do it with masstagger. Then I wish masstagger can rename the files directly from txt file.

foo_tradersfriend

Reply #21
oh well, forget that idea

foo_tradersfriend

Reply #22
<edit>FLAC Fingerprint Writing would be a nice feature, but shouldn't be integrated into a Masstager component. Anyone up for foo_ffp?</edit>

dev0
"To understand me, you'll have to swallow a world." Or maybe your words.

foo_tradersfriend

Reply #23
I noticed this plugin doesn't write tracknumber tags.  Out of curiousity, what's the reasoning behind this, and is there another easy way to do it?  I thought I had way with "Guess from filename" but my newness hasn't gotten it to work.

Any info appreciated.

Despite

foo_tradersfriend

Reply #24
Quote
I noticed this plugin doesn't write tracknumber tags.  Out of curiousity, what's the reasoning behind this, and is there another easy way to do it?  I thought I had way with "Guess from filename" but my newness hasn't gotten it to work.

Any info appreciated.

Despite

Easy ways to add tracknumber:
  • "Auto tracknumber" for single disc shows.
  • "Guess values from filename" for multi disc shows.
    For filenames like um2001-06-21dYrX.ext use the format "um%date%d%disc%t%tracknumber%". With filenames like these the plugin can also deduce disc and tracknumbers, even if it does not write the tracknumber.
I might add tracknumber writing later today. I don't really remember what was the reason for not doing it.