Skip to main content

Topic: Changes Made to TAG.EXE (Read 137064 times) previous topic - next topic

0 Members and 1 Guest are viewing this topic.
Changes Made to TAG.EXE
Reply #100
My Review of Tag 2.0.52

I have been using computers since before the DOS days.  I am very familiar with DOS.  Yet, because the documentation of Tag.EXE was incomplete and inaccurate, it took me FOUR HOURS TO FIGURE THE THING OUT.  I almost gave up.  It would've been faster to just copy and paste into the ID3's.

The Tag.TXT text file shows an example ID3 insertion SCHEME as A - N - T, but it does not show the entire example command line.  I tried numerous times, even going to the author's, "Synthetic Soul", forum he frequents:  Hydrogenaudio Forums.  If you use a free email address to sign up, you can't even post for FIVE DAYS!  Left on my own, I finally figured out the SCHEME I wanted has the following correct syntax:
Tag --auto --scheme "X-A - T" *.mp3

Notice the quotes.  Tag.TXT also contradicts itself when using slashes for SCHEME.  At the top it shows a backslash and at the bottom, for options, it shows a forward slash.  Although "-t <item=x>", "-f <item=x>" and "--fromfile <file>" are mentioned under options, I have no clue how to actually implement them.  WHAT is "item=x"?  How exactly do you use a text file and how do you match its lines up with the MP3 file ID3 info you're trying to change?  The Tag.TXT file needs more complete examples with correct syntax.

While the program appears to work correctly, because of very poor documentation, its potential will never be fully realized.  I recommend to Synthetic Soul that he correct and add to the included Tag.TXT file.  Also, for SCHEME, I recommend a more robust implementation of the "X" option (text to be disregarded).  I wanted to disregard the first 3 numerical digits of each MP3 which are followed by a {space}.  Unfortunately, Tag.EXE can't do this.  A DOS-type wildcard convention would help using "?"'s or maybe using "X" as single characters when there are more than one as in "XXX".

Reviewed at Softpedia Tag 2.0.43 user reviews

  • Synthetic Soul
  • [*][*][*][*][*]
  • Global Moderator
Changes Made to TAG.EXE
Reply #101
  • I am not the author, I simply made some amendments to Case's Tag.  Read the first review on that page.
  • I did not submit the application to Softpedia; either somebody else did or they scraped it.
  • The fact that you have to wait five days before posting on HA, and the fact that means that you have not asked for support until writing your review are not my, or Case's, problem.
  • item=x: "item" is the tag name, "x" is the value, e.g.: -t "Artist=Pixies".  This could be ascertained from the help file.
  • --fromfile is used to copy tags from another audio file, not a text file.  This does confuse some people.
  • I have no intention of further developing Case's Tag, or updating the documentation.
I'm on a horse.

Changes Made to TAG.EXE
Reply #102
Synthetic Soul,
  • I understand you are not the original author.
  • N/A
  • I was able to find the correct syntax on my own.  However, it would have been faster and easier if Tag.TXT had been more complete and accurate.
  • I did not read anything regarding "item=x" or its correct syntax.
  • --fromfile:  OK, I assumed the source was a text file.
  • No further Tag.TXT editing:  That's a shame.  Tag.EXE is a good program which is useful for quickly modifying large numbers of MP3's.  Since you are the current custodian of Tag.EXE, I assumed you would want to improve its documentation.  Editing Tag.TXT would probably only take a couple days for someone with your knowledge of the program.  I encourage you to modify Tag.TXT to make it clearer with more syntax complete commands and more information regarding the other commands.  This would make it easier for new users to run it and make it more universally accepted.


{out}

  • Synthetic Soul
  • [*][*][*][*][*]
  • Global Moderator
Changes Made to TAG.EXE
Reply #103
Your understanding of Tag probably exceeds mine.  I only used Tag for basic operations, mainly tagging from file.  Given that I only wrote 1% of the code, I am no expert on the other 99%.
I'm on a horse.

  • gottkaiser
  • [*][*][*]
Changes Made to TAG.EXE
Reply #104
Hello Synthetic Soul,

I tried copying the tags from one flac file to another flac file.
I used this batch line:
Code: [Select]
"file-path\Tag.exe" --fromfile "file-path\name.flac" "file-path\name.lossy.flac"

Tag.exe accepts the line but is crashing during processing.
One flac file is processed with lossyWAV.exe. (original.flac and lossy.flac)
I tried copying the tags from the original to the lossy.flac file.
If you'd like I could provide them for you. (they are quite small)


Any help would be appreciated. (even referral to another method)
  • Last Edit: 17 January, 2010, 10:54:28 PM by gottkaiser

  • hawkeye_p
  • [*][*][*]
Changes Made to TAG.EXE
Reply #105
What do you mean with "crashes"?

Does the tag.exe process hang or vanish?

The first could come from tag.exe choking on the LYRICS tag.
  • Last Edit: 18 January, 2010, 03:29:10 AM by hawkeye_p

  • Synthetic Soul
  • [*][*][*][*][*]
  • Global Moderator
Changes Made to TAG.EXE
Reply #106
IIRC --fromfile is actually used to tag from a text file containing the tag information.

I'm afraid I can't be any more help than that.  I don't think that it is possible with Tag with one command line.  You could possibly use the ability to write a tag's content to file (--tostdoutn) in conjunction with the ability to tag using the contents of a file (-f); however that would require two commands per tag, and there has to be an easier way.

Personally, I'd use foobar for this.
I'm on a horse.

  • hawkeye_p
  • [*][*][*]
Changes Made to TAG.EXE
Reply #107
That's not correct, Neil: --fromfile indeed copies the tag information from a tagged file.
Nevertheless I'd also use foobar for this task (in the meantime, as you know  )

  • Synthetic Soul
  • [*][*][*][*][*]
  • Global Moderator
Changes Made to TAG.EXE
Reply #108
 Just goes to show that I don't use Tag much.  Not sure where I got that idea, but I was quite confident about it!

I'm sorry, but there isn't a hope in Hell of me fixing this.  I don't have the skillz.

Edit: Ha! Scroll up to post #102 (mainly .5)...  I knew there was general confusion on the switch, but thought it was the other way around...
  • Last Edit: 18 January, 2010, 05:03:06 AM by Synthetic Soul
I'm on a horse.

  • hawkeye_p
  • [*][*][*]
Changes Made to TAG.EXE
Reply #109
I might have, but I prefer spending my time with other things. 

If gottkaiser indeed has the problem with tag .exe, my workaround will help:

- export lyrics from source file to temp file
- remove lyrics from source file
- copy tags
- add lyrics to both files

You also might find the foobar solution easier ...

  • hawkeye_p
  • [*][*][*]
Changes Made to TAG.EXE
Reply #110
Edit: Ha! Scroll up to post #102...


Yes, that's embarrassing 

  • gottkaiser
  • [*][*][*]
Changes Made to TAG.EXE
Reply #111
You could possibly use the ability to write a tag's content to file ([font= "Courier New"]--tostdoutn[/font]) in conjunction with the ability to tag using the contents of a file ([font= "Courier New"]-f[/font]); however that would require two commands per tag

I tried to put it together for one tag but failed. My knowledge about [font= "Courier New"]stdout[/font] and how to use it is not good enough.
Could you give an universal valid example for one tag?

Thanks for your help so far.

  • Synthetic Soul
  • [*][*][*][*][*]
  • Global Moderator
Changes Made to TAG.EXE
Reply #112
Here is an example.

The following line will output the contents of the tag "mytagname" to STDOUT, and write that to a text file (tag.txt) in your temp directory:
Code: [Select]
tag --tostdoutn mytagname source.flac>%TMP%\tag.txt

The following line will then set the tag "mytagname" from the contents of the same text file:
Code: [Select]
tag -f "mytagname=%TMP%\tag.txt" destination.flac

It would probably be best to join these using &&, so that the second command will only fire if the first is successful.  Also, you could tidy up by deleting the temporary file.

This leaves us with:

Code: [Select]
TAG --tostdoutn mytagname source.flac>%TMP%\tag.txt && TAG -f "mytagname=%TMP%\tag.txt" destination.flac && DEL %TMP%\tag.txt

You would have to repeat this for every tag that you want to copy over. If you were doing this in a batch file you could ease your pain a little by using variables to replace the tag, source and destination values.

There has to be an easier way...
I'm on a horse.

  • gottkaiser
  • [*][*][*]
Changes Made to TAG.EXE
Reply #113
I came up with this lines to copy a tag from a "name.flac" to a "name.lossy.flac" file:
Code: [Select]
"%~dp0Tag.exe" --tostdoutn "REPLAYGAIN_ALBUM_GAIN" "%~dpn1.flac" >> "%~dp0tmp.txt"
set /p TOOLOUTPUT= < "%~dp0tmp.txt"
del "%~dp0tmp.txt"
"%~dp0Tag.exe" -u "REPLAYGAIN_ALBUM_GAIN=%TOOLOUTPUT%" "%~dpn1.lossy.flac"

This means at the moment I use a temporary text file.

Is there another more direct way without temporary file?

Edit:
I saw your answer to late :-) Big thanks to you!
If anybody has an idea for a direct (without temporary file) way it would please share it.
  • Last Edit: 18 January, 2010, 07:50:13 AM by gottkaiser

  • Synthetic Soul
  • [*][*][*][*][*]
  • Global Moderator
Changes Made to TAG.EXE
Reply #114
I guess Tag would need to be able to tag from STDIN to be able to skip that phase, and I don't think that it can.
I'm on a horse.

  • Synthetic Soul
  • [*][*][*][*][*]
  • Global Moderator
Changes Made to TAG.EXE
Reply #115
How about this:

Code: [Select]
METAFLAC --export-tags-to=- source.flac | METAFLAC --import-tags-from=- destination.flac

Edit: Note that you may get duplicate tags if destination.flac is already tagged.  To be on the safe side maybe you could use:

Code: [Select]
METAFLAC --remove-all-tags destination.flac && METAFLAC --export-tags-to=- source.flac | METAFLAC --import-tags-from=- destination.flac
  • Last Edit: 18 January, 2010, 07:56:11 AM by Synthetic Soul
I'm on a horse.

  • gottkaiser
  • [*][*][*]
Changes Made to TAG.EXE
Reply #116
Big big thanks!
the metaflac method was what I searched for.

Do you have an idea for copying the picture tag?
I tried:
Code: [Select]
METAFLAC --no-utf8-convert --export-picture-to=- source.flac | METAFLAC --no-utf8-convert --import-tags-from=- destination.flac

but its gives me an error .

I guess it has to do with the command "--import-tags-from" I' not sure about the proper specification for the picture.


Again thanks for your troubles.
  • Last Edit: 18 January, 2010, 08:46:00 AM by gottkaiser

  • Synthetic Soul
  • [*][*][*][*][*]
  • Global Moderator
Changes Made to TAG.EXE
Reply #117
It doesn't look like you can use STDIN with --import-picture-from.  It looks like you'd have to export to a file and import from there.

Code: [Select]
METAFLAC --remove-all-tags destination.flac && METAFLAC --export-tags-to=- --export-picture-to=temp.jpg source.flac | METAFLAC --import-tags-from=- --import-picture-from=temp.jpg destination.flac

I'm no expert with metaflac though (or Tag it seems!) so really your guess is as good as mine.
I'm on a horse.

  • gottkaiser
  • [*][*][*]
Changes Made to TAG.EXE
Reply #118
I'm no expert with metaflac though (or Tag it seems!) so really your guess is as good as mine.

Your line works. Now I can finish my personal batch project.   
Thanks very much! Again.

  • Bjossi
  • [*]
Changes Made to TAG.EXE
Reply #119
I am making some batch scripts (one per album) that will auto-encode & tag files for me. Tag.exe will come in handy because some of these files have characters that command-line will turn into garbage when receiving them directly from a batch file. Well, that was what I hoped for before I ran into trouble. Wildcards work great for making Tag and the encoder read filenames with foreign characters, but the tagging is more tricky it seems.

Example of my usage: Tag --chreplace "Comment=Test =a x" C:\test.wv (=a will return " according to Tag.cfg). but the resulting tag will be Test =a x, not Test " x. Does the char replacing only work in automatic modes? If so, then does anyone know good alternate methods to get foreign characters into tags (and filenames also) from a batch script? Only method I found working is using -f and lead to a text file containing the tag value, but it seems awfully inconvenient to make hundreds of text files for my project as a whole. Would be great if I could specify which line to read from within a text file, like -f 14 "Title=C:\tag.txt".

Thanks in advance!

  • muzack
  • [*][*][*]
Changes Made to TAG.EXE
Reply #120
hello, i've searched for hours for a commandline tagger or better ID3 Tag reading tool.
Tag.exe is the best but I think I need something impossible (because none of the tools I've found offer that)
Why is it not possible to print out Non Standard tags like <PUID> or stuff like that.
I set custom tagfields in foobar2000 with some additional info and I need to get these info over command line and write it into a textfile or something like that.
Is this generally possible?

thanks for any hint m.

  • sirmax
  • [*]
Changes Made to TAG.EXE
Reply #121
I have made some improvements:

Version 2.0.53:
(+) Added M4A support for reading (alac.exe is required).
(-) Fixed Lyrics3 v2.0 writing.
(*) Reviewed ID3v2 code.

Win32 binaries and sources attached.

  • selyb
  • [*]
Changes Made to TAG.EXE
Reply #122
if you or anyone else plans any more updates, I have a request: Show multiple tag info

my problem is if the audiophile has more than one type of tag (e.g. some.mp3 has id3v2.4+id3v1.1) then tag.exe picks the first one it recognizes and displays only the info from that tag
so, if id3v1 is complete and id3v2 is present but all blank, then tag.exe will display that it contains a tag but all blank entries

What I'm asking is that tag.exe instead shows all tag formats for each file e.g.
Code: [Select]
c:\my.mp3
Format:  MPEG 1 Layer 3, Joint Stereo
Details: 44100 Hz Stereo, 211 kbps, playtime 03:52
[ID3v2]
Title:   You Make Me Sick
Artist:  Egypt Central
Album:   Egypt Central
Year:    2008
Track:   2
Genre:   Rock
Comment:
ENCODEDBY=Exact Audio Copy   (Secure mode)
replaygain_album_gain=-10.43 dB
replaygain_album_peak=1.216547
replaygain_track_gain=-10.62 dB
replaygain_track_peak=1.195923
[ID3v1]
Title:   You Make Me Sick
Artist:  Egypt Central
Album:   Egypt Central
Year:    2008
Track:   2
Genre:   Rock
Comment:
[APE v2.0]
Title:   You Make Me Sick
Artist:  Egypt Central
Album:   Egypt Central
Year:    2008
Track:   2
Genre:   Rock
Comment:
ENCODEDBY=Exact Audio Copy   (Secure mode)
replaygain_album_gain=-10.43 dB
replaygain_album_peak=1.216547
replaygain_track_gain=-10.62 dB
replaygain_track_peak=1.195923

  • semiflacco
  • [*]
Changes Made to TAG.EXE
Reply #123
Hi,

An issue and a question about the --paranoid option:

- I'm running tag.exe 2.0.52 and --help does not show the --paranoid option. I've been writing a script recently and opted to work around the lack of a return code because I thought it wasn't available and only stumbled on the option today when I noticed a reference to it in some release notes for an earlier version. Perhaps something has gone wrong with the code to display help?

- Can anyone please tell me what the return codes are? I've searched and can only find that (as expected) we get non-zero for errors or warnings, but no more detail than that. I've tested with a read-only file and find that it works (great!) and I get an errorlevel of 32 so I'm guessing there is some bitsetting going on, but would really like to distinguish between "Failed to write but no damage done", and "Ooops, just chewed up your file" so my script can respond appropriately.

Thanks in advance.

  • TagUser
  • [*]
Changes Made to TAG.EXE
Reply #124
@sirmax and other developers:

Is there any chance, that we get id3v2 WRITE support?

From the --help we know:
Main features:
* Support for multiple standards:
  - ID3v1.x
  - ID3v2.x (reading and removing)
but I'm desperately looking for a possibility to WRITE id3v2-tags.
I would like to write all my metadata in id3v2.3, not only in id3v1.

And +1 for selyb's request to show multiple tags, especially the one's with different content.