Simple app for my music collection
  • Acolyte of the Butterfly
    Acolyte of the Butterfly
    Travis_H
    Posts: 147 from 2009/12/17
    From: Salem, Oregon,...
    Hi all,

    Over the years, I've used my various Amithlon and MorphOS machines to rip and save my CDs digitally. I've used Google free music locker since the beginning and have uploaded 15k+ songs. Now it's time to transition to YouTube Music, which doesn't seem very exciting, so I downloaded my collection. I now have a folder with ALL FIFTEEN THOUSAND SONGS thrown in together. My goal is to get them grouped back into folders so Plex will have a better time organizing them for me.

    However, I've been trying to use MusicBrainz Picard on the Mac to get it done and it hasn't gone well. I do have a question in their forums about the software, but most people aren't grasping my needs:

    I want to move the files into newly created folders using the Album tag only. That's all! Nothing crazy.

    My question: Could one of the fine software designers who create awesome, task-specific programs come up with something for me (preferably with a simple GUI) that accomplishes just that?
  • »14.09.20 - 21:54
    Profile
  • Yokemate of Keyboards
    Yokemate of Keyboards
    Zylesea
    Posts: 2057 from 2003/6/4
    Quote:

    Travis_H schrieb:
    Hi all,

    Over the years, I've used my various Amithlon and MorphOS machines to rip and save my CDs digitally. I've used Google free music locker since the beginning and have uploaded 15k+ songs. Now it's time to transition to YouTube Music, which doesn't seem very exciting, so I downloaded my collection. I now have a folder with ALL FIFTEEN THOUSAND SONGS thrown in together. My goal is to get them grouped back into folders so Plex will have a better time organizing them for me.

    However, I've been trying to use MusicBrainz Picard on the Mac to get it done and it hasn't gone well. I do have a question in their forums about the software, but most people aren't grasping my needs:

    I want to move the files into newly created folders using the Album tag only. That's all! Nothing crazy.

    My question: Could one of the fine software designers who create awesome, task-specific programs come up with something for me (preferably with a simple GUI) that accomplishes just that?



    Do I get it right: Just browse the files (selected files/dirs by file requester or sniffing entire volumes), get the album title and put (probably move not copy) all files of the same album title in one directory? If so that does not seem to be a biggie. ATM I am a bit too busy, but in 2-3 weeks I should have spare time again. Maybe this function would be a nice extention to Exutil, my Exif based renaming tool.
    --
    http://via.bckrs.de

    Whenever you're sad just remember the world is 4.543 billion years old and you somehow managed to exist at the same time as David Bowie.
    ...and Matthias , my friend - RIP
  • »14.09.20 - 22:24
    Profile Visit Website
  • Acolyte of the Butterfly
    Acolyte of the Butterfly
    Travis_H
    Posts: 147 from 2009/12/17
    From: Salem, Oregon,...
    Yes, that's it!

    Just to clarify, the new folder name would be drawn from the album title in the .mp3 tag, not something in filename. Then moved (to save space, or copied, for safety) to a folder named from said tag.

    It's funny because the MusicBrainz crowd is so focused on using their tools and the databases to re-tag the files, which is something I don't need or want.

    I would be eternally grateful for such a simple and elegant tool!
  • »14.09.20 - 22:45
    Profile
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    KennyR
    Posts: 878 from 2003/3/4
    From: #AmigaZeux, Gu...
    Not terribly helpful I know, but this is the kind of task that Directory Opus (now Windows-only) excels at doing.

    I have to wonder that, on MorphOS, if it's possible to cheat and script this by tagging the album title to the filename, using a simple wildcard pattern match to move to the correct directory, then renaming the files back to remove the album name. But I don't have the skills to do that myself, and you may bump into the filename length restriction.
  • »14.09.20 - 22:51
    Profile
  • ASiegel
    Posts: 1374 from 2003/2/15
    From: Central Europe
    Quote:

    Travis_H wrote:
    My goal is to get them grouped back into folders so Plex will have a better time organizing them for me.

    Well, have you actually tried Plex yet? Has it failed to detect all/most songs? It supposedly uses audio fingerprinting to detect songs so it should be able handle thousands of songs in a folder.
  • »15.09.20 - 01:23
    Profile
  • Just looking around
    DrMaybe
    Posts: 17 from 2018/6/3
    From: Norway
    i made an arexx script 20 years ago for copy/move mp3 files and C64 SID files to directorys made from the artist/album (plus more) name. Should work in morphos. see if I can find it
  • »15.09.20 - 22:39
    Profile
  • Acolyte of the Butterfly
    Acolyte of the Butterfly
    Travis_H
    Posts: 147 from 2009/12/17
    From: Salem, Oregon,...
    From the Plex support pages:

    "Content should have each artist in their own directory, with each album as a separate subdirectory within it.

    Music/ArtistName/AlbumName/TrackNumber - TrackName.ext

    Tip!: Even if your music content has complete and perfect embedded tags, we strongly encourage you to continue organizing tracks into albums. Using a flat file list of tracks can result in failures or a poor experience."

    Additionally, I have an untold number of songs and albums that were created from recording LPs digitally, stripping audio from YouTube videos and long-lost webcasts of music. All this material would not show up in a database search.

    But I guess I could point it to the folder and watch what happens.
  • »15.09.20 - 22:44
    Profile
  • Acolyte of the Butterfly
    Acolyte of the Butterfly
    Travis_H
    Posts: 147 from 2009/12/17
    From: Salem, Oregon,...
    Quote:

    DrMaybe wrote:
    i made an arexx script 20 years ago for copy/move mp3 files and C64 SID files to directorys made from the artist/album (plus more) name. Should work in morphos. see if I can find it


    Very cool! I would love to try it out.
  • »15.09.20 - 22:45
    Profile
  • Acolyte of the Butterfly
    Acolyte of the Butterfly
    Posts: 141 from 2017/8/7
    I personally would use a 2pass method:
    1. use mp3tagger to rename all tunes to Album+title+ whatever,
    2. use BRU (batch rename utility) to create the desired structure finally from that.

    nothing for MorpOS tho.
    But these two are well proven in their field and work.
  • »16.09.20 - 05:39
    Profile
  • jPV
  • Yokemate of Keyboards
    Yokemate of Keyboards
    jPV
    Posts: 2068 from 2003/2/24
    From: po-RNO
    Quote:

    Zylesea wrote:
    Do I get it right: Just browse the files (selected files/dirs by file requester or sniffing entire volumes), get the album title and put (probably move not copy) all files of the same album title in one directory? If so that does not seem to be a biggie. ATM I am a bit too busy, but in 2-3 weeks I should have spare time again. Maybe this function would be a nice extention to Exutil, my Exif based renaming tool.

    The hardest part for you is probably to get the title out of the tag reliably, at least when coding with Hollywood if you don't have code to extract data from tags. There's A-MC's ID3Tag library for Hollywood, but it's little limited (supports v1 and v2.3.0 tags only) and little buggy (calculates tag sizes wrong), but if all the tags in MP3 files are in the supported versions, it probably works fine and would make the task easier for you.

    I coded an MP3 tag editor myself and that library simply wasn't enough, and I had to code support for more versions (v1.0, v1.1, v1+, v2.2.0, v2.3.0, and v2.4.0) by myself from scratch. It's a bit mess with all those versions and encodings you might come up, and some encoders/editors stretching the standard etc :) Very time consuming stuff to get it right and tested with all cases...

    Soo... I also might do something for the issue, but if that A-MC's library or something else would be enough, and you would like to add this feature to Exutil, it would be nice... I don't have time for new projects for at least couple of weeks either :)
  • »16.09.20 - 07:06
    Profile Visit Website
  • Acolyte of the Butterfly
    Acolyte of the Butterfly
    Travis_H
    Posts: 147 from 2009/12/17
    From: Salem, Oregon,...
    Just for the fun of it, I pointed Plex to a backup of the folder with 15k songs in it. For some time, it looked like it was going to work, but eventually just bombed out and showed one single song! I tried several times, deleting the library and what not. Plex just doesn't like it.
  • »16.09.20 - 21:53
    Profile
  • Yokemate of Keyboards
    Yokemate of Keyboards
    Zylesea
    Posts: 2057 from 2003/6/4
    Quote:

    jPV schrieb:

    The hardest part for you is probably to get the title out of the tag reliably, at least when coding with Hollywood if you don't have code to extract data from tags. There's A-MC's ID3Tag library for Hollywood, but it's little limited (supports v1 and v2.3.0 tags only) and little buggy (calculates tag sizes wrong), but if all the tags in MP3 files are in the supported versions, it probably works fine and would make the task easier for you.

    I coded an MP3 tag editor myself and that library simply wasn't enough, and I had to code support for more versions (v1.0, v1.1, v1+, v2.2.0, v2.3.0, and v2.4.0) by myself from scratch. It's a bit mess with all those versions and encodings you might come up, and some encoders/editors stretching the standard etc :) Very time consuming stuff to get it right and tested with all cases...

    Soo... I also might do something for the issue, but if that A-MC's library or something else would be enough, and you would like to add this feature to Exutil, it would be nice... I don't have time for new projects for at least couple of weeks either :)


    jPV, thank you for that information. I actally hadn't thought much about how to extract information from the files yet. I thought I 'd probably go the route as I have done with getting the exif information: read a bit about the format, do a few assumptions and then do a few simple pattern matching/string processing functions. For the exif stuff this worked rather fine albeit I got into issues whith the extraction of more detailed (and not needed) information (e.g. gps position).

    Maybe I am lucky, in contrast to an mp3 tag editor I only need to sniff around a bit - no need to modify anything. That's easier.
    --
    http://via.bckrs.de

    Whenever you're sad just remember the world is 4.543 billion years old and you somehow managed to exist at the same time as David Bowie.
    ...and Matthias , my friend - RIP
  • »16.09.20 - 22:18
    Profile Visit Website
  • MorphOS Developer
    jacadcaps
    Posts: 3082 from 2003/3/5
    From: Canada
    It shouldn't be that hard to extract that info using Reggae... Some tiny shell app perhaps.
  • »16.09.20 - 22:23
    Profile Visit Website
  • MorphOS Developer
    jacadcaps
    Posts: 3082 from 2003/3/5
    From: Canada
    Well, there you go:

    Binary at multimediatags.lha

    Source code at github

    Now this won't sort files into folders, but it will dump the selected tags, so it should be trivial to do the rest in Lua or even Arexx.
  • »17.09.20 - 03:57
    Profile Visit Website
  • Acolyte of the Butterfly
    Acolyte of the Butterfly
    Travis_H
    Posts: 147 from 2009/12/17
    From: Salem, Oregon,...
    Quote:

    jacadcaps wrote:
    Well, there you go:

    Binary at multimediatags.lha

    Source code at github

    Now this won't sort files into folders, but it will dump the selected tags, so it should be trivial to do the rest in Lua or even Arexx.


    Alright, half-way there!

    You know, my wife gives me crap for holding on to my "alternative" computers. When I read her the first few posts from this thread from total strangers willing to help me out with some esoteric request, she actually had to admit that the close-knit aspect of the Amiga community was a real positive.

    Thanks, all!
  • »18.09.20 - 13:06
    Profile
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    Templario
    Posts: 544 from 2012/4/28
    @Travis_H
    Quote:


    some esoteric request


    And you live in Salem, not it is not esoteric request, is a witch request.
    Sorry the word and city give me the idea for this post.

    [ Editado por Templario 18.09.2020 - 18:32 ]
  • »18.09.20 - 17:30
    Profile
  • Acolyte of the Butterfly
    Acolyte of the Butterfly
    Travis_H
    Posts: 147 from 2009/12/17
    From: Salem, Oregon,...
    Sorry, wrong Salem. I'm over 3,000 miles from the famous one in Massachusetts!
  • »19.09.20 - 00:17
    Profile
  • Just looking around
    DrMaybe
    Posts: 17 from 2018/6/3
    From: Norway
    I have uploaded the script to aminet.
    SIDMP3Sorter.zip

    the script was written 20 years ago and worked with the existing id3 code at the time however, it is not tested with updated versions of id3. so caution should be made (I did a test on morphos and It worked great, but still)

    BTW:

    jacadcaps:

    multimediatags file.mp3 <-- this works great!

    multimediatags "device:dir/dir/file.mp3" <-- gives blank :-(
  • »23.09.20 - 23:15
    Profile
  • Yokemate of Keyboards
    Yokemate of Keyboards
    Zylesea
    Posts: 2057 from 2003/6/4
    Quote:

    DrMaybe schrieb:
    I have uploaded the script to aminet.
    SIDMP3Sorter.zip

    the script was written 20 years ago and worked with the existing id3 code at the time however, it is not tested with updated versions of id3. so caution should be made (I did a test on morphos and It worked great, but still)

    BTW:

    jacadcaps:

    multimediatags file.mp3 <-- this works great!

    multimediatags "device:dir/dir/file.mp3" <-- gives blank :-(




    Travis, have you tried DrMaybe's script? Sounded like it would do the task you were asking for.
    If not I'll fire up my editor and do a little Hollywood programming.
    --
    http://via.bckrs.de

    Whenever you're sad just remember the world is 4.543 billion years old and you somehow managed to exist at the same time as David Bowie.
    ...and Matthias , my friend - RIP
  • »30.09.20 - 20:08
    Profile Visit Website
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    polluks
    Posts: 799 from 2007/10/23
    From: Gelsenkirchen,...
    Quote:

    DrMaybe schrieb:
    multimediatags "device:dir/dir/file.mp3" <-- gives blank :-(

    Works fine :-)
    Code:
    > multimediatags "System Backup:Reggae/file_example_MP3_700KB.mp3"
    Title: Impact Moderato
    Performer: Kevin MacLeod
    Album: YouTube Audio Library
    Pegasos II G4: MorphOS 3.9, Zalman M220W · iMac G5 12,1 17", MorphOS 3.18
    Power Mac G3: OSX 10.3 · PowerBook 5,8: OSX 10.5, MorphOS 3.18
  • »02.10.20 - 17:55
    Profile
  • Acolyte of the Butterfly
    Acolyte of the Butterfly
    Posts: 141 from 2017/8/7
    Just out of curiosity, are the different char encodings handled by MorphOS and how/where?
  • »02.10.20 - 18:33
    Profile
  • Order of the Butterfly
    Order of the Butterfly
    igracki
    Posts: 411 from 2003/2/25
    From: Berlin
    If you haven't copy your mp3s already, here is a little script which creates a directory from the album name and copies it to this directory.
    The new directory will be created in the current directory.

    I use the "cp" command from the SDK to copy the mp3 file, because the Copy command can't copy a file to directory if it contains wildcards! So maybe you need to install the SDK or just copy the "cp" command from it.

    Code:

    .key mp3/A
    .bra {
    .ket }

    ; Copy a mp3 file to a subdirectory which is its album name

    ;set dir "`mmtags "{mp3}" AL Q`"
    set dir "`multimediatags "{mp3}" NOTITLE NOPERFORMER NOTRACK NOAUTHOR QUIET`"

    IF NOT "$dir" EQ ""
    ; the Copy command can't copy a file to a directory which has wildcards (like "["), so I use SDK's cp command
    IF NOT EXISTS "$dir"
    MakeDir "$dir"
    ENDIF
    gg:bin/cp "{mp3}" "$dir/"
    ELSE
    Echo "The mp3 file '{mp3}' doesn't have an Album name!"
    ENDIF


    Copy the above script to s:CopyMP3 and protect it with "+s".

    This script only handles one mp3 file, to do this for all your mp3s, you can use the List command to create a temporary script to copy all your mp3 files.

    Code:

    List mp3: ALL LFORMAT "s:CopyMP3 *"%p%n*"" > t:copyall

    Replace the "mp3:" with the location of your mp3 files!

    To execute this temporarly script, type "Execute t:copyall" into a shell window.
  • »04.10.20 - 01:23
    Profile Visit Website
  • Acolyte of the Butterfly
    Acolyte of the Butterfly
    Travis_H
    Posts: 147 from 2009/12/17
    From: Salem, Oregon,...
    Quote:

    Zylesea wrote:

    Travis, have you tried DrMaybe's script? Sounded like it would do the task you were asking for.
    If not I'll fire up my editor and do a little Hollywood programming.


    I did give it a try on a couple dozen files. It was able to create a directory from the 'artist' tag and copy over one of the files. Then it output this error message:

    Please Wait While Counting Files...DONE!
    +++ Error 16 in line 323: Function did not return value
    Command returned 10/16: <This space intentionally left blank!>
    rx failed returncode 10

    I suspect it has something to do with a missing tag in one of the .mp3s?
  • »09.10.20 - 21:17
    Profile
  • Just looking around
    DrMaybe
    Posts: 17 from 2018/6/3
    From: Norway
    No! is not a missing tag that is the problem, but a tag with a different version than I made the script for. The script is old and the way I read out the tag values is quite crude. I only tested the script on a small selection of files and it seemed to work. I guess the scrip will need some major rework to be of great use today. Unfortunately!
  • »09.10.20 - 22:38
    Profile