Results 1 to 10 of 10

Thread: M3U Path Update app?

  1. #1
    Newbie
    Join Date
    Mar 2004
    Posts
    18

    M3U Path Update app?

    I'm going to automatically sync my mp3 collection with the home network using insync from http://www.dillobits.com/ which is a great file sync program BTY. It does my 65Gb +12,000 collection very quickly. I plan to setup multiple jobs to sync up movies, grab whatever files I put into a specified directory, new movies, etc.

    The problem comes in when I try and use my playlists from the master library. They have a path of D:\<Artist>\<Artist> - <Album> - <Track> - <Title>.mp3
    My media engine directory is under C:\Documents and Settings\Car\My Documents\My Music\.... Which causes the playsists to not find any media.

    M3U supports both relative and absolute paths as described here:
    http://gonze.com/playlists/playlist-...urvey.html#M3U

    Hoever, when I converted the absolute paths on the playlists in the master library (Home Server) and send them over to the car, ME would not play them. Thoes playlists show no valid entries or somtehting like that. They did work in Winamp outside of ME. My collection is just to large to build them all in the car. It would take ages. Plus I have all my friends build a playlist of there own. When people come over for the night to hang out, I add all there playlists together so everyone gets to hear music they like. I want to do the same thing in the car without having to rebuild all the playlists.

    So my question, should I submit this as a bug since ME is not conforming to the M3U Spec?

    Would anyone be willing to write a simple find and replace app I could run at the end of my update that would look for string X (d:\ or whaever) and replace with string Y (c:\..... or whatever) which could be used to update the playsists each time they are copied across.

    The third option, I'm willing to work on this issue. I do datawarehousing related stuff for the telecos. I'd be happy to help out with ME development from a DB prespective. The problem is I don't know VC++, and it's been a while since I've written any C. Anyway, if i can help let me know.

  2. #2
    I'm sorry, and you are....? frodobaggins's Avatar
    Join Date
    Jan 2003
    Location
    Ruston, LA
    Posts
    8,846
    Gimme 10 minutes, I'll whip one up.
    [H]4 Life
    My next generation Front End is right on schedule.
    It will be done sometime in the next generation.
    I'm a lesbian too.
    I am for hire!

  3. #3
    Constant Bitrate OdysseyPC's Avatar
    Join Date
    Oct 2003
    Location
    ACT, Australia
    Posts
    114
    Quote Originally Posted by frodobaggins
    Gimme 10 minutes, I'll whip one up.
    And the clock is still ticking ...

    From one dedicated programmer to another, I know what it's like to give yourself 10mins knowing full well you can do it in 10mins and you do indeed have a working copy within 10mins ... BUT ... you get that urge, the evil demon of generic perfection, if this guy wants to use it someone else may too ... after a while feature creep sets in and half an hour later you have this program that does everything and anything but clouds the original intent.

    Or maybe you just got 5 mins in and the telephone rang, anyways, just thinking aloud ... Keep up the good work and I respect your dedication to helping others.
    Caputer Mk. II
    '02 VX Holden Commodore Series II Executive
    MII12000, 512MB RAM, 60GB HDD (5400rpm), 16X DVD, TS200V
    Morex 60W DC-DC, Custom S/SDC
    OS/Software: Developing...

  4. #4
    I'm sorry, and you are....? frodobaggins's Avatar
    Join Date
    Jan 2003
    Location
    Ruston, LA
    Posts
    8,846
    Quote Originally Posted by OdysseyPC
    And the clock is still ticking ...

    From one dedicated programmer to another, I know what it's like to give yourself 10mins knowing full well you can do it in 10mins and you do indeed have a working copy within 10mins ... BUT ... you get that urge, the evil demon of generic perfection, if this guy wants to use it someone else may too ... after a while feature creep sets in and half an hour later you have this program that does everything and anything but clouds the original intent.

    Or maybe you just got 5 mins in and the telephone rang, anyways, just thinking aloud ... Keep up the good work and I respect your dedication to helping others.

    SEX

    BTW, I'm done, just gotta write instructions.
    [H]4 Life
    My next generation Front End is right on schedule.
    It will be done sometime in the next generation.
    I'm a lesbian too.
    I am for hire!

  5. #5
    Raw Wave rando's Avatar
    Join Date
    Mar 2004
    Location
    Redondo Beach, CA
    Posts
    1,973
    I belive this can be done quite trivially using the native XP cmd shell (see the extended FOR command options and environment variable string substitution). It should look something like the 1 liner below.

    @echo off && (for /f "tokens=*" %I in (oldplaylist) do ((set z=%I) && (echo !z:badpath=goodpath! >> newplaylist))) && @echo on

    ** Make sure you run cmd /E:ON /V:ON first to enable command extensions and delayed environment variable expansion


    It can definitely be done trivially within the Windows Script Host hosted languages (VBScript,...). It's too late for me to start this 10 minute task (likely to become hours).

  6. #6
    I'm sorry, and you are....? frodobaggins's Avatar
    Join Date
    Jan 2003
    Location
    Ruston, LA
    Posts
    8,846
    Here it is:

    ReplaceStringInFile.zip

    Code:
    Program  Name: ReplaceStringInFile
    Author:  Kevin Lincecum
    Alias:   FrodoBaggins
    Contact: [email protected]
             OR PM FrodoBaggins on the MP3Car.com Forums
    
    
    Functions:
    
        Replaces a string with another string in a specified file.
    
    Syntax:
        file$ = the file name
        find$ = the string TO replace
        replacewith$ = the string that replaces find$
        
        ReplaceStringInFile.exe file$,find$,replacewith$
    
    Example:
    
        ReplaceStringInFile.exe Blues.m3u,D:\MP3,Y:\Music
    
        Would replace all instances of "D:\MP3" with "Y:\Music" in the file "Blues.m3u"
    
    
    
    Remember:
       CASE SENSITIVE! Replaces the strings EXACTLY as you type them.
    
    
    
    License to use this software:
        This software is free for all commercial and non-commercial uses
        provided the following conditions are met:
    
            1. SetVolume is E-mail ware. Send me an e-mail and tell me your opinion, etc.
            2. Any commercial users must first notify the author and obtain written
               permission prior to distributing the product.
    	3. This program may not be included in any repository or mass distribution
               system without prior written permission from the author.
            4. This README.TXT is included unaltered. (May be renamed to SETVOLUME.TXT)
    
    
    Copyright 2004 Kevin Lincecum
    [H]4 Life
    My next generation Front End is right on schedule.
    It will be done sometime in the next generation.
    I'm a lesbian too.
    I am for hire!

  7. #7
    I'm sorry, and you are....? frodobaggins's Avatar
    Join Date
    Jan 2003
    Location
    Ruston, LA
    Posts
    8,846
    Quote Originally Posted by rando
    I belive this can be done quite trivially using the native XP cmd shell (see the extended FOR command options and environment variable string substitution). It can definitely be done trivially within the Windows Script Host hosted languages (VBScript,...). It's too late for me to start this 10 minute task (likely to become hours).

    Trivial for some of us, not for others, gotta always remember that.
    [H]4 Life
    My next generation Front End is right on schedule.
    It will be done sometime in the next generation.
    I'm a lesbian too.
    I am for hire!

  8. #8
    Raw Wave rando's Avatar
    Join Date
    Mar 2004
    Location
    Redondo Beach, CA
    Posts
    1,973
    Quote Originally Posted by frodobaggins
    Trivial for some of us, not for others, gotta always remember that.
    Yah yah, but he said he does DB stuff and used to do some C. This is trivial enough for anyone with those credentials. Also, I updated my post with the 'approximate' 1 line shell command to do the job.

    Now off to bed for me.

  9. #9
    Newbie
    Join Date
    Mar 2004
    Posts
    18

    Thanks, I'll try it tonight.

    Yah yah, but he said he does DB stuff and used to do some C. This is trivial enough for anyone with those credentials. Also, I updated my post with the 'approximate' 1 line shell command to do the job.
    I used to be a TA for the C lab, so I'm pertty good with it, but I haven't used it in 5 years. I could have figured it out, but it would have takend me hours, compared to somebody who has the environment set up and does this stuff all the time, it just didn't make sense for me to do it.

    I work with large (+7Tb) datawarehouses that process 100-400M records a day. I go in and run studies on that, develop new applications, products, etc. I've always been weak on the scripting side. I usually just grab an SE to write me a quick Perl/shell script for this kind of stuff.

    Thanks Frodo! Can I use wildcards for the file argument? Guess I'll find out when I try it.

  10. #10
    I'm sorry, and you are....? frodobaggins's Avatar
    Join Date
    Jan 2003
    Location
    Ruston, LA
    Posts
    8,846
    Quote Originally Posted by chance_11
    Thanks Frodo! Can I use wildcards for the file argument? Guess I'll find out when I try it.
    No, it is a literal string replacement only.
    [H]4 Life
    My next generation Front End is right on schedule.
    It will be done sometime in the next generation.
    I'm a lesbian too.
    I am for hire!

Similar Threads

  1. Anyone Help Test a GPS App?
    By ukchris in forum Software & Software Development
    Replies: 42
    Last Post: 04-08-2004, 03:37 PM
  2. new app linux/windows
    By hijinks21 in forum Software & Software Development
    Replies: 13
    Last Post: 11-18-2003, 07:25 AM
  3. Problems with VB program as external app
    By zolakk in forum ME Archive
    Replies: 3
    Last Post: 07-09-2003, 10:36 PM
  4. Question about m3u format
    By brentp4 in forum Software & Software Development
    Replies: 6
    Last Post: 02-19-2002, 04:41 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •