PortableApps.com wins big in the 2009 Community Choice Awards and hits 100 million app downloads!

MediaMonkey Portable 3.1.1 [Launcher Only]

Submitted by Devo on December 1, 2008 - 10:24am

Application: MediaMonkey
Category: Media
Description: MediaMonkey is a digital media player and media library application developed by Ventis Media Inc., for organizing and playing audio on Microsoft Windows operating systems. By using plugins, it can be extended to handle video and other media formats as well.
Instructions: There are instructions for installing MediaMonkey portably in the root folder.

Download MediaMonkey Portable 3.1.1 Launcher Test 2 [625KB download / 1.18MB installed]
(MD5: 3a1ad002edf0210d4df9722210500b64)

This is the initial release and I wasn't able to test it on a system with MediaMonkey already installed, so if you find any bugs that break the local install, let me know. There is also one thing that I would eventually like to fix, but I don't know how: The launcher does not update the paths for any scripts that are installed. If there are any ideas, please let me know.

EDIT: I also would like to be able to edit MM.db to update the drive path. This would eliminate the need to use the Watch Folders within MediaMonkey and save some time during startup. If anybody knows how to do this, please post the code below.

Release Notes:

Test 2 (2009-09-11): Updated to latest PAF specs
Added support to save Scripts.ini across sessions
New icon


Test 1 (2008-12-01): Initial release


( categories: )

BEAUTIFUL

This worked beautifully!! I just copied my local install folder to the folder on my pen drive. Scripts, extensions, settings all just the same. Even if I changed portable settings, they didn't reflect the home install nor vice-versa. Just like taking my monkey to work with me.

Let me know if it keeps the

Let me know if it keeps the same settings while you're at work. If you change any of the settings at work, see if they are kept when you try it out at home again.

I'll give it a go.

I'll give it a go.

The day Microsoft produces something that doesn't suck is
probably the day they start producing vaccuum cleaners. (author unknown)

Everything stays on both

Everything stays on both versions. Settings, themes, skins, databases are kept for each version. If you install a new script/skin it will only installl for the version you have open at the time of installation.Now if Media Monkey isn't open at the time, it will default to the local install, but that's to be expected.

fully loaded and pro

i have bought media monkey in the past and then said i dodnt recieve the code,but i did and they sent me another one and of which was a different one to what i already had,the one i bought i will keep but the other one is registered and is also in a txt document within the file,when u use portable app to install an app it will open a window and you will have to manualy brouse for the portable apps folder as it doesnt work properly when u go to extract it with out brousing,then load it up and sort ur music out,

[Link removed by mod Tim, your statements above indicate that you should not be doing this, it is not legal. Do not post links to illegal software in our forums]

3.1.1?

Anyone know if this will work with the new version, 3.1.1?

(Their wiki has info on portabalizing, I wish they made it easier)

I am not my signature.

Still good

I just upgraded earlier today and everything is still working. You cannot use the built in upgrade function, you have to download the MM installer, extract the contents and copy it over your portable version.

The only thing that changed between 3.1.1 and the previous version was that they fixed a problem with auto-tagging from Amazon.com so it is a simple upgrade.

Update to 3.1.1

This updates the launcher to Test 2. See original post for more information.

MediaMonkey 3.1.2.1266 Beta :(

MediaMonkey 3.1.2.1266 Beta cannot be extracted with Universal Extractor. Why?

Not Supported [Fixed]

It looks like MM upgraded to a new version of the installer that is not supported by UniExtract. Here's the log file from UniExtract:

Signature detected: Inno Setup Setup Data (5.3.3) (u)
This is not directly supported, but i'll try to unpack it as version 5203
; Version detected: 5303
Critical error: The setup files are corrupted. Please obtain a new copy of the program.
Unpacking failed. This version is not supported.

EDIT: So I figured it out. UniExtract uses an older version of the installer that MM was created with. You need to download the latest version and add it to UniExtract/bin. The post describing it can be found here. Clicking the innounp link takes you to another page and you need to hit the download link. You should be directed to a sourceforge page. Then copy this into UniExtract/bin replacing the old one.

Yes!

Thanks Devo!!
It works for me!

GREAT!

This was a good find - I hope it makes it into release. I've been using a modified "portable" Media Monkey for a while, and it's good to see a real one emerging. I'll be using it actively and will let you know if I have any issues.

MM.DB

I'm not sure if this is expected or not, but MediaMonkey is creating a folder in my Local AppData directory (I'm using Windows 7). As I mentioned before I had a previous version of MM that was made portable (not through the portable apps platform - I think it was through ini settings) and pretty much everything stayed in the MM folder on my portable. It would create a folder in my Local AppData, but only put a m3u file in there which I could live with.

This version is copying over my MM.DB database from my portable location to the Local AppData location on the harddrive...

Nevermind - I see what it's doing. It copies these files over to the hard drive and then copies them back to the portable when MM closes. Is this normal? Is there a way to prevent it from behaving like this?

UPDATE=================
I reinstalled the portable version from scratch and it's working as expected now - nothing is being copied over to my Local AppData folder. Something must have gone funky with the MM ini file last time.

MM 3.2

I see they've released v3.2 of MediaMonkey. I tried using UniExtract but with out any luck, even with the fix mentioned above. So I installed in on my computer and copied the files over to the portable directory and so far everything is working great.

I'm also using this with the portable version of Winamp that's here on the forums (setting MediaMonkey to use the winamp player) and it's working great. The only issue I've noticed, which I've mentioned before, is that it creates a folder under local AppData folder and stores some temp m3u files there which it removes when the program is closed.

This isn't an issue for me, but would MediaMonkey be considered a true portable app and be able to be released if it's doing this?

Make sure you get the right version

I downloaded this file and replaced the one that was in UniversalExtractor and it unpacked properly. Let me know if you have any problems with unpacking it or if you find any bugs. I have noticed that the folder you are speaking of is not cleaned up in Windows 7, but I haven't come across it in XP.

I had a quick look at the MM.db file !

Hi Devo,

But as far as I could see it uses relative paths.
Could have missed something, cause the file is very big.

If this is the case and there would be any drive letters, they have to be local files, which you would have to get rid of anyway in a portable version.

So my advise is, keep on using the watch folders. This option actually is perfect.

The way I (will) have this done in Winamp is : (in the next test release)

The launcher checks for the system drive serial number (drive letter is not good enough, cause 2 different PC's could give the same drive letter)
If new and old serial are equal, keep old media library.
If new and old serial are not equal, delete media library and use watch folders. (and have it check for the drive letter of course)

This way the launcher keeps the existing media library when the user uses MediaMonkeyPortable on the same computer. But as well there couldn't be any missing files in the media library, when using another Pc !

Ps.: I have read about, that there even is a possibility that the same Pc could give different drive letters to the same flash drive. So also you would need to add this in your script.

[edit] Did you try to update the drive letter to mediamonkey.m3u. I have seen some ini options to remove missing files ?

Portable Apps, Altiris SVS and Steady State. There is nothing else to wish for!

I'm pretty sure MM.db uses

I'm pretty sure MM.db uses absolute paths, otherwise when you change computers it would have no problem playing files.

I guess I don't understand why you need to use the serial number. If you just change the drive letter of each file in MM.db, that should be sufficient for MediaMonkey to play the files. The folder structure hasn't changed, just the drive letter that the usb is plugged in to.

Also, the size of MM.db depends on how many files you have in your library, so you could just make a small library and use that to test functionality.

EDIT: here's a bunch of information I found on the MM.db. I don't really know much about computers, so I don't know if it's helpful or not. If you want you can take this over because I think the scope of what I would like to do is far above what I know how to do.

EDIT 2: I don't know how to update drive letters. I don't really have the time for the next few months to learn how to either.

Just testing with fewer music files at the moment

The reason I am explaining about the drive letter, is that users would probably add local files/folders to the library, which would be missing when using it on different PC !

Checked the MM.db with smaller library (still it is a lot of data to go through) but didn't find any drive letters

00032ec0: 00 00 00 01 0D 0D 0D 0D 0D 0D 19 01 01 4D 00 61 ; .............M.a
00032ed0: 00 6E 00 75 00 20 00 43 00 68 00 61 00 6F 00 0B ; .n.u. .C.h.a.o..
00032ee0: 43 00 6C 00 61 00 6E 00 64 00 65 00 73 00 74 00 ; C.l.a.n.d.e.s.t.
00032ef0: 69 00 6E 00 6F 00 4D 00 61 00 6E 00 75 00 20 00 ; i.n.o.M.a.n.u. .
00032f00: 43 00 68 00 61 00 6F 00 31 00 30 00 57 00 65 00 ; C.h.a.o.1.0.W.e.
00032f10: 6C 00 63 00 6F 00 6D 00 65 00 20 00 74 00 6F 00 ; l.c.o.m.e. .t.o.
00032f20: 20 00 54 00 69 00 6A 00 75 00 61 00 6E 00 61 00 ;  .T.i.j.u.a.n.a.
00032f30: 3A 00 5C 00 44 00 6F 00 63 00 75 00 6D 00 65 00 ; :.\.D.o.c.u.m.e.
00032f40: 6E 00 74 00 73 00 5C 00 4D 00 75 00 73 00 69 00 ; n.t.s.\.M.u.s.i.
00032f50: 63 00 5C 00 4D 00 61 00 6E 00 75 00 20 00 43 00 ; c.\.M.a.n.u. .C.
00032f60: 68 00 61 00 6F 00 5C 00 43 00 6C 00 61 00 6E 00 ; h.a.o.\.C.l.a.n.
00032f70: 64 00 65 00 73 00 74 00 69 00 6E 00 6F 00 5C 00 ; d.e.s.t.i.n.o.\.
00032f80: 57 00 65 00 6C 00 63 00 6F 00 6D 00 65 00 20 00 ; W.e.l.c.o.m.e. .
00032f90: 74 00 6F 00 20 00 54 00 69 00 6A 00 75 00 61 00 ; t.o. .T.i.j.u.a.
00032fa0: 6E 00 61 00 2E 00 6D 00 70 00 33 00 FF 46 00 6F ; n.a...m.p.3.ÿF.o

Portable Apps, Altiris SVS and Steady State. There is nothing else to wish for!

Adding local files inherently

Adding local files inherently breaks portability. The idea is that the user would use a local install to play local files. It is their own computer, why would they have music files on their computer and no music player? The music player on the usb drive would play files that are located on the usb drive as well. That way users would be able to take their media library with them. This is the concept behind portable apps.

No, but thank you !

Not for now I want to take this over cause I am to busy with my current project.

As well Media Monkey has the same problem as Winamp does, leaving cookies and stuff through their browsers.

Maybe if I really can't get any further with Winamp Portable I will have a look on disabling the browser for Media Monkey, cause leaving traces is a no go for PA.c !

Ps.: But hey, don't give up just like this. I was just offering to help you !

Portable Apps, Altiris SVS and Steady State. There is nothing else to wish for!

I'm not really giving up, I

I'm not really giving up, I just don't have the time to figure things out right now. Also, I have no idea how to change the drive letters. If you know how to please post and I'll try to get around to adding that functionality.

Also, what program are you using to view MM.db?

Drive letters

I am using a non freeware program to do it, but it is easy enough just opening windows notepad and drag 'n drop MM.db on to the notepad window. The data will be pretty clear that way.

By the way, after I actually got some local folders in MM.db, still I couldn't find any drive letters. You'll have to try and see for your self. So I suggest you keep the Watch Folders the way they are now, seems to work fine.

Besides the MM.db file, for all the other MM settings files I came across, the drive letter update isn't that hard.
Make sure you include the last two lines of the following in to your script

;=== Include
!include "Registry.nsh"
!include "GetParameters.nsh"
!include "MUI.nsh"
!include TextReplace.nsh
!include ReplaceInFileWithTextReplace.nsh

Add the following, as a file 'Other\Source\ReplaceInFileWithTextReplace.nsh'
If there is a newer version, could somebody please correct it !!!

; ReplaceInFile wrapper for testreplace function
; John T. Haller of PortableApps.com
; BSD License
; Requires TextReplace plugin installed in NSIS and !include "TextReplace.nsh" in main nsi
;
; Usage: ${ReplaceInFile} SOURCE_FILE SEARCH_TEXT REPLACEMENT
; or use ReplaceInFileCS for case-sensitive (use when possible, it's faster)
; No return variable.  Error will be set if unable to do the replacement (invalid file, locked file, etc)

Function ReplaceInFile
	Exch $0 ;REPLACEMENT
	Exch
	Exch $1 ;SEARCH_TEXT
	Exch 2
	Exch $2 ;SOURCE_FILE
	Exch 3
	Exch $3 ;CASE_INSENSITIVE
	Push $4 ;NEW_FILE
	Push $5 ;RETURN_VALUE
	
	StrCpy $4 `$2.OldReplaceInFile`
	
	${textreplace::ReplaceInFile} "$2" "$4" "$1" "$0" "$3 /C=0" $5
	
	IntCmp $5 0 StackCleanup ReturnError RenameToOriginal
	
	ReturnError:
		SetErrors
		Goto StackCleanup
	
	RenameToOriginal:
		Delete $2
		Rename $4 $2
	
	StackCleanup:
		Pop $5
		Pop $4
		Pop $3
		Pop $0
		Pop $1
		Pop $2

		${textreplace::Unload}
FunctionEnd

!macro ReplaceInFileCS SOURCE_FILE SEARCH_TEXT REPLACEMENT
	Push `/S=1`
	Push `${SOURCE_FILE}`
	Push `${SEARCH_TEXT}`
	Push `${REPLACEMENT}`
	Call ReplaceInFile
!macroend

!macro ReplaceInFile SOURCE_FILE SEARCH_TEXT REPLACEMENT
	Push `/S=0`
	Push `${SOURCE_FILE}`
	Push `${SEARCH_TEXT}`
	Push `${REPLACEMENT}`
	Call ReplaceInFile
!macroend

!define ReplaceInFileCS '!insertmacro "ReplaceInFileCS"'

!define ReplaceInFile '!insertmacro "ReplaceInFile"'

Use the instruction in your script, like this :

${ReplaceInFile} "$SETTINGSDIRECTORY\MediaMonkey\mediamonkey.m3u" $OLDDRIVELETTER $NEWDRIVELETTER

Have a look how for example Notepad++Portable deal with it, it isn't that complicated !

Portable Apps, Altiris SVS and Steady State. There is nothing else to wish for!

Thanks for this. Now for the

Thanks for this. Now for the real question, hopefully you'll be able to answer this one too:

How does MediaMonkey store the file paths then? If it was simply relative paths, then the media library would work as long as the media and MediaMonkey were on the same drive. This isn't the case. Whenever you switch computers and the drive letter changes, MediaMonkey can not longer find the media. This is what led me to believe that MediaMonkey somehow uses absolute paths.

The problem with using the file monitor is that every time it rescans it adds jpgs and other random files to the library. If you look under the node for Unknown Artists you will see a ton of files. I've also noticed that the File Monitor doesn't remove missing tracks. I think this is a bug with MediaMonkey itself though.

This is a problem !

Your right they aren't relative, neither absolute in the standard format (D:\Folder\File.mp3). But have a go through the data, the way I explained before (or get info on the site you mentioned) , maybe you will find how MM saves the drive letter. If you find it I could help you to code the drive letter update for MM.db.

Isn't there an ini option to exclude extensions ?
About the missing tracks, you could just delete the MM.db at every launch !

Portable Apps, Altiris SVS and Steady State. There is nothing else to wish for!

For missing files in mediamonkey.m3u......

You could use the following code to deal with them, it doesn't really remove missing files, but it removes files which aren't located on the flashdrive. If you get the launcher to only update 'n remove when ever MMportable is being used on a different Pc, it should be what you need !

Use it instead of ${ReplaceInFile}
Make sure $6 contains $SETTINGSDIRECTORY\MediaMonkey\mediamonkey.m3u

  StrCpy $0 $OLDDRIVELETTER
  StrCpy $1 $NEWDRIVELETTER
  StrCpy $6 $SETTINGSDIRECTORY\MediaMonkey\mediamonkey.m3u
  FileOpen $R0 $6 r                 ;open file to read
  GetTempFileName $R2               ;get temp file name
  FileOpen $R1 $R2 w                ;open temp file to write
  FileRead $R0 $R3                       ;read first line '#EXTM3U'
  FileWrite $R1 $R3                  ;write first line
UnR_Loop:
  FileRead $R0 $R3
  IfErrors UnR_End
  StrCpy $5 $R3 1 ; get first char
  StrCmp $5 "#" UnR_JustFileInfo ; check whether it is drive letter or not
  StrCpy $R4 $R3
  goto UnR_Skip
UnR_JustFileInfo:
  FileRead $R0 $R4
UnR_Skip:
  StrCpy $R5 $R4 1 1 ; get second char
  StrCmp $R5 ":" UnR_IsDriveletter ; check whether is relative (just in main playlist)
  Goto UnR_Write
UnR_IsDriveletter:
  StrCpy $4 $R4 3                ; get drive letter
  StrCmp $4 $0 0 UnR_Loop ; compare old drive letter to line-driveletter
  StrCpy $R4 $R4 "" 3 ; remove drive letter
  StrCpy $R4 "$1$R4" ; add new drive letter
UnR_Write:
  StrCmp $5 "#" 0 +2
         FileWrite $R1 $R3                  ;write line
  FileWrite $R1 $R4                  ;write line
  Goto UnR_Loop

  UnR_End:
    FileClose $R1                   ;close writen file
    FileClose $R0                   ;close read file

    Delete "$6.old"                 ;delete old file, if still exists after last replace
    Rename "$6" "$6.old"            ;rename original file
    Rename "$R2" "$6"               ;move/rename replaced file
  ClearErrors

This is just a quick fix, I have been using it for Winamp, so it also recognizes url's and relative paths. See if it works on mediamonkey.m3u.
It should, but if not let me know and I'll have a better look at it ?

Portable Apps, Altiris SVS and Steady State. There is nothing else to wish for!