![]() ![]() |
Apr 3 2011, 13:01
Post
#46
|
|
|
Member Group: Full Members Posts: 46 Joined: 2-March 08 From: Belgium Member No.: 6578 Mp3tag Version: 2.52 |
I was wondering if a .src command block can be reused in other .src (similar to INCLUDE command in some programming languages).
This way a tag related command block could be saved in a file which can be included in several .src files. This post has been edited by Victor Kostas: Apr 4 2011, 23:56 |
|
|
|
Apr 6 2011, 01:18
Post
#47
|
|
![]() Member Group: Full Members Posts: 1571 Joined: 15-March 09 From: Germany Member No.: 9103 Mp3tag Version: 2.50 |
Wouldn't it be better if each tag related command block is saved in a separate file so it can be reusable in script (.src) source files? http://forums.mp3tag.de/index.php?showtopi...amp;#entry53987 A nice-to-have option. Thus you change centrally a tag related source code. And each script file could be easier managed. I'm answering you here since I think your question at the discogs script topic is not releated specially to this script, right? What you propose there is not possible with mp3tag. You can't combine .src files like you can combine actions to action groups. You would have to run every script for every tag for it's own, so you would run about 15 scripts for one album! I was wondering if a .src command block can be reused in other .src (similar to INCLUDE command in some programming languages). This way a tag related command block could be saved in a file which can be included in several .src files. But you can reuse command blocks in other scripts. Just copy them and insert them into your own script. The only tricky thing is that the new script finds the right place in the web source where the comand block is belonging. |
|
|
|
Apr 6 2011, 20:57
Post
#48
|
|
|
Member Group: Full Members Posts: 46 Joined: 2-March 08 From: Belgium Member No.: 6578 Mp3tag Version: 2.52 |
I'm answering you here since I think your question at the discogs script topic is not releated specially to this script, right? What you propose there is not possible with mp3tag. You can't combine .src files like you can combine actions to action groups. You would have to run every script for every tag for it's own, so you would run about 15 scripts for one album! But you can reuse command blocks in other scripts. Just copy them and insert them into your own script. The only tricky thing is that the new script finds the right place in the web source where the comand block is belonging. I think you didn't get my point. I never wrote to combine .src files. What I mean is to not write the same group of commands in each .src file but put this in a separate file (obviously not .src). e.g. following block commands "extracts" Album. CODE # Album outputto "Album" findline "class=\"profile" findline "href=\"/artist" regexpreplace "^.+</a>" "</a>" findinline "</a>" findinline " - " sayuntil "</h1>" Instead of inserting the very same code to each .src file you save the block to a file (e.g. album.sri). You include the file (include album.sri) on each .src file. A change to album.sri file would affect all .src files using it. This way you manage centrally your code. A simple change on how you extract a particular tag wouldn't require a change of all .src files. So the question now is: Would it be feasible to add a new command INCLUDE <filename>.sri ? I hope it it is clear now. This post has been edited by Victor Kostas: Apr 6 2011, 21:00 |
|
|
|
Apr 6 2011, 22:17
Post
#49
|
|
![]() Member Group: Full Members Posts: 1571 Joined: 15-March 09 From: Germany Member No.: 9103 Mp3tag Version: 2.50 |
|
|
|
|
Oct 13 2011, 17:18
Post
#50
|
|
|
Member Group: Full Members Posts: 9 Joined: 20-September 09 Member No.: 10958 Mp3tag Version: 2.44 |
Hello,
I have a request, would it be possible to add search by ASIN for the various Amazon web sources ? I mainly use amazon.co.uk. Thanks, Martin. |
|
|
|
Oct 13 2011, 20:27
Post
#51
|
|
![]() Moderator Group: Moderators Posts: 5506 Joined: 4-September 03 From: Germany Member No.: 201 Mp3tag Version: 2.55a |
Just enter the ASIN in the search field, it should find the album.
-------------------- |
|
|
|
Oct 13 2011, 22:02
Post
#52
|
|
|
Member Group: Full Members Posts: 9 Joined: 20-September 09 Member No.: 10958 Mp3tag Version: 2.44 |
Just enter the ASIN in the search field, it should find the album. Ok will try that I was actually trying to match to an MP3 download on there and I've found the script that handles those (I have a different problem with not finding the Artist on there though the script seems to be looking in the right place and the US lokup is working - but I will post in the thread for that script) Thanks, Martin |
|
|
|
![]() ![]() |
|
Lo-Fi Version | Time is now: 23rd May 2013 - 21:57 |