MyBB Internal: One or more warnings occurred. Please contact your administrator for assistance.
MyBB Internal: One or more warnings occurred. Please contact your administrator for assistance.
MyBB Internal: One or more warnings occurred. Please contact your administrator for assistance.
MyBB Internal: One or more warnings occurred. Please contact your administrator for assistance.
Nightingale Forums - Playlist export: Keep uppercase letters in Windows

Nightingale Forums

Full Version: Playlist export: Keep uppercase letters in Windows
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Hi,

I'm using Nightingale 1.12.1 on Windows 7 (64 bit) and want to export my playlists to Linux based computers. I have already tried the AddOn "Playlist Export" and a modified version I already used in Songbird.
The problem is that the resulting paths in the export files in Nightingale are completely in lower case letters. That is no problem on Windows, because the title m:\musik\abba\angel eyes.mp3 is found in Windows when it is M:\Musik\Abba\Angel eyes.mp3 in reality. But in linux /media/Musik/musik/abba/angel eyes.mp3 can't be found when it is /media/Musik/Musik/Abba/Angel eyes.mp3 in reality.
I have playlists with several hundreds of entries and the folder structure of my music files is the same in Windows and in Linux.
Exporting in Songbird worked with capital letters but in Nightingale it doesn't. So I compared the modified versions of the playlist export addon, that I'm using in Songbird and Nightingale with Winmerge. But there wasn't any. So there might be a difference in the databases where the results are fetched?

Has anybody a way to get playlists with capital letters? I already tried to import the playlist in VLC (Windows) and export it again. But you only get capital letters if you play every song of the list first...

Best regards,

Stefan
(05-26-2016, 11:08 PM)Nafetz Wrote: [ -> ]Exporting in Songbird worked with capital letters but in Nightingale it doesn't. So I compared the modified versions of the playlist export addon, that I'm using in Songbird and Nightingale with Winmerge. But there wasn't any. So there might be a difference in the databases where the results are fetched?

I don't have a Windows system available right now, but can you verify that the correct case is actually stored in the database (that is, right-click the column header of the main library playlist, select "File Location" and then have a look into the now displayed column)?

If the information is not stored, the playlist exporting would have to actively fetch the correct case from windows (which I'm quite sure it doesn't do, but it sounds possible to add that; there is probably a performance impact, though).

I'm curious why Songbird and Nightingale behave differently. Did you import the music through the same feature (manual import, watch folder, drag-and-drop, ...) in both Songbird and Nightingale?
Thank you very much for your help.
I'm very very confused now....
I believed that some months ago the export in Nightingale resulted in a list with capital letters. But I wasn't sure.
This morning I opened Songbird (a long time after the last use). Then I exported a playlist and got a list with capital letters. Because I have a modified version of export playlist I deactivated it for testing reaons and installed the original one. I also got capital letters with Songbird. So I deinstalled the official Plugin and activated my modified version again and closed Songbird.

Now I wanted to make some screenshots and found out that Songbird is exporting the playlists only with lower case letters ....???????
I don't have any explanation for this.

I'm close to believe that this was only imagination........  Huh

The funny thing is: I deleted all "evidence" this morning, so there is no chance for me, to prove for myself that there were capital letters....

And to answer your question: All letters in "File Location" are lower case in both programs. And both programs got the files by watching a folder.
But things are easier now since both programs behave the same ... at least now ... Confused


Ok - so to continue "scientific". Is there a way, to convert lower case playlists in Windows to capital letters (if they are stored on paths with capital letters)?
(05-27-2016, 04:13 AM)Nafetz Wrote: [ -> ]Ok - so to continue "scientific". Is there a way, to convert lower case playlists in Windows to capital letters (if they are stored on paths with capital letters)?

I'd guess that is possible. But it might actually be easier to do this in Nightingale, unless you're good as Windows scripting (I'm not) or have a msys or cygwin installed (so you can use bash or something like that, then looping through the file with realpath is probably all you need, assuming casing is handled similar to symlinks, not sure about that right now).

In Nightingale, you could edit the playlist export add-on to construct a nsiFile and use file.path or something (unsure what's available on Nightingale's old Gecko, as Mozilla thought it would be a great idea to unfreeze interfaces).
Ok - found a (very dirty) solution. If somebody's having the same problem some time later - this is what I did:
I wrote a autoit-script, to read all single files out of the exported list and open them automatically into VLC-Player. When this is finished you have to store the VLC session into a playlist - the result has capital letters Smile

Code:
#include <File.au3>

PlaylistUpperCase()

Func PlaylistUpperCase()

   $sFilePath = "D:\Benutzer\Stefan\Desktop\SWR1 - Hitparade 2008 BW.m3u"
   $sVLCTitle = "VLC media player"
   $sVLCFileOpenTitle = "Eine oder mehrere Dateien zum Öffnen wählen"

   $iCountLines = _FileCountLines ( $sFilePath )

   ; Open the file for reading and store the handle to a variable.
   Local $hFileOpen = FileOpen($sFilePath, $FO_READ)
   If $hFileOpen = -1 Then
       MsgBox($MB_SYSTEMMODAL, "", "An error occurred when reading the file.")
       Return False
   EndIf

   Local $i = 3
   Local $sFileRead = ""

   MsgBox($MB_SYSTEMMODAL, "", "Make sure VLC is running and active!!!!")

   WinWaitActive($sVLCTitle)

   While $i <= $iCountLines

      $sFileRead = FileReadLine($hFileOpen, $i)
      Send("^o")
      WinWaitActive($sVLCFileOpenTitle)
      Sleep(400)
      Send($sFileRead, 1)
      Send("{ENTER}")
      WinWaitClose($sVLCFileOpenTitle)
      $i = $i + 2;

   WEnd

   ; Close the handle returned by FileOpen.
   FileClose($hFileOpen)

   MsgBox($MB_SYSTEMMODAL, "", "Ready!!!!")

EndFunc

Insert values for sFilePath (your m3u path and filename), sVLCTitle (the title of the VLC-window) and sVLCFileOpenTitle (the title of the open-media dialogue of VLC) to make in run on your system. The first file path has to be in line 3 and then in every odd line.

I tested the script to convert a list with 1000 entries. This took about 25 minutes (that are 40 songs per minute) but didn't need any user interaction - just wait until it is ready. Don't use your computer while the script is running because the script is sending commands to the window that is active. To run the script VLC has to be active.

Not perfect, but much better than changing the playlist manually Wink


-------------------------
Edit:
Hi rsjtdrjgfuzkfg, seems like you have written your answer almost the same time than me. Thank you very much - that would probably be the better way. But I still got problems to understand how the AddOns are exactly working. So I'll keep it this way at least for the beginning Big Grin
(05-28-2016, 02:15 AM)Nafetz Wrote: [ -> ]Not perfect, but much better than changing the playlist manually Wink

I'd guess changing the playlist export add-on is both cleaner and faster, but I'm glad you found a solution that worked sufficiently for you Wink
(05-28-2016, 02:15 AM)Nafetz Wrote: [ -> ]that would probably be the better way

At least on github that has already been implemented: This preference enables what I suggested (and has been there for at least 3 years). There should be a preference in the add-ons preferences.... Tongue
(05-28-2016, 02:33 AM)rsjtdrjgfuzkfg Wrote: [ -> ]At least on github that has already been implemented: This preference enables what I suggested (and has been there for at least 3 years). There should be a preference in the add-ons preferences.... Tongue

Shocking...
I never saw that there was a field like that in the preferences Blush
But  - it doesn't work on my Windows computer. It says "Make sure paths are correct case (takes longer to export)". But the result is lower case no matter what is selected.
I had a look in the database yesterday - maybe the information of uppercase or lowercase is already lost in Nightingale. I couldn't find a record where there is a uppercase letter in a path...
(05-28-2016, 03:08 AM)Nafetz Wrote: [ -> ]But  - it doesn't work on my Windows computer. It says "Make sure paths are correct case (takes longer to export)". But the result is lower case no matter what is selected.
You did a restart of Nightingale after changing the setting? Just in case, in theory reopening the playlist export window should be sufficient.

(05-28-2016, 03:08 AM)Nafetz Wrote: [ -> ]I had a look in the database yesterday - maybe the information of uppercase or lowercase is already lost in Nightingale. I couldn't find a record where there is a uppercase letter in a path...
It is definitively not stored. The option causes Nightingale to re-query the name directly from the file system, that's why it is slower and not enabled by default.
Yes, I did a restart. I tried again today but without success. Im using the version from http://wiki.getnightingale.com/doku.php?...ist_export

I couldn't test the version from github because I get an installation error ("installation script not found" -204)
Pages: 1 2