INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Request: m3u extended Playlist without path  (Read 1330 times)

vsolivas

  • Recent member
  • *
  • Posts: 6
Request: m3u extended Playlist without path
« on: October 26, 2019, 01:53:46 am »

If it would be possible, the Sony Walkman doesn't recognize playlists with a path before the filename. I've been having to open the m3u extended playlist file in TextEdit (on a Mac) and delete the path. It's annoying, and would be a great feature, as it would make syncing my Walkman that much easier. I'm not talking about a relative path. No path at all. Attached is an example of a playlist of podcasts that works with my Walkman.

This isn't urgent, I can deal with changing the m3u file myself for now. But it would really solve a bugaboo I have with Media Center.
Logged

RoderickGI

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 8186
Re: Request: m3u extended Playlist without path
« Reply #1 on: October 26, 2019, 05:23:48 pm »

That can be done now, by the look. I just had to check.

If your device drive is say "M:\", and you select the "Playlist Path" as M:\, with the "Playlist Format" set as "M3U Extended", then the Playlist will include just the filename.

I did a small test with one file, and it produced the following Playlist file;

#EXTM3U
#EXTINF:469,Relax My Dog - Music and Sounds Designed for Puppies
Music and Sounds Designed for Puppies.mp3


Have you tried that combination of settings?
Logged
What specific version of MC you are running:MC27.0.27 @ Oct 27, 2020 and updating regularly Jim!                        MC Release Notes: https://wiki.jriver.com/index.php/Release_Notes
What OS(s) and Version you are running:     Windows 10 Pro 64bit Version 2004 (OS Build 19041.572).
The JRMark score of the PC with an issue:    JRMark (version 26.0.52 64 bit): 3419
Important relevant info about your environment:     
  Using the HTPC as a MC Server & a Workstation as a MC Client plus some DLNA clients.
  Running JRiver for Android, JRemote2, Gizmo, & MO 4Media on a Sony Xperia XZ Premium Android 9.
  Playing video out to a Sony 65" TV connected via HDMI, playing digital audio out via motherboard sound card, PCIe TV tuner

vsolivas

  • Recent member
  • *
  • Posts: 6
Re: Request: m3u extended Playlist without path
« Reply #2 on: October 26, 2019, 07:00:03 pm »

I'm using the Mac version of the software, so I don't have the drive letter associated with my device. There's just /Volumes/device/. But when I change the path of the playlist to / or leave it blank or change it to just "device", the playlist gets loaded into a seperate folder on the device, still with the path to the filename.
 
Logged

RoderickGI

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 8186
Re: Request: m3u extended Playlist without path
« Reply #3 on: October 27, 2019, 01:53:09 am »

Sorry, I didn't notice this was the Mac forum. My bad.

If the Device Path is set to /Volumes/device/, which I assume it is because it looks like you are loading all the file into the same directory, and into the root directory of the device, then also set the "Playlist Path" to /Volumes/device/.

Basically, if the file and Playlist paths are the same, your problem may be fixed. But you will have to try that. It's worth a try anyway.

Note that leaving the "Playlist Path" blank in Windows results in no Playlist file being loaded onto the device. So that isn't going to work, assume the Mac version works the same. Setting the "Playlist Path" to "/" would be meaningless on a Mac I would expect, which would mean MC ignores that setting.
Logged
What specific version of MC you are running:MC27.0.27 @ Oct 27, 2020 and updating regularly Jim!                        MC Release Notes: https://wiki.jriver.com/index.php/Release_Notes
What OS(s) and Version you are running:     Windows 10 Pro 64bit Version 2004 (OS Build 19041.572).
The JRMark score of the PC with an issue:    JRMark (version 26.0.52 64 bit): 3419
Important relevant info about your environment:     
  Using the HTPC as a MC Server & a Workstation as a MC Client plus some DLNA clients.
  Running JRiver for Android, JRemote2, Gizmo, & MO 4Media on a Sony Xperia XZ Premium Android 9.
  Playing video out to a Sony 65" TV connected via HDMI, playing digital audio out via motherboard sound card, PCIe TV tuner

vsolivas

  • Recent member
  • *
  • Posts: 6
Re: Request: m3u extended Playlist without path
« Reply #4 on: October 27, 2019, 02:23:48 am »

Nope doesn't work. It just puts the playlist in a folder of path /Volumes/device/. But the playlist is the same. Base path appended on the file name.
Logged

RoderickGI

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 8186
Re: Request: m3u extended Playlist without path
« Reply #5 on: October 27, 2019, 03:17:07 am »

Hmmm, I guess the handling of a URI is different to assigned drive letters.

You could try just putting a dot "." in the "Playlist Path", which means current directory, even on a Mac I believe. But I'm just guessing a bit now.   :-\

EDIT: I tried this on Windows and it worked, exactly like using a "Playlist Path" of M:\. I did note though that MC change my setting of "." to ".\", so maybe it will change the setting to "./" for you on the Mac, or maybe you will need to enter "./".

Note that the Handheld Sync functionality does handle paths differently for different OS's, and handles different devices differently. For example a device defined as a drive letter is handled differently to a mobile device connected via USB. So, no guarantees, and if the above doesn't work, I guess JRiver will have to comment.
Logged
What specific version of MC you are running:MC27.0.27 @ Oct 27, 2020 and updating regularly Jim!                        MC Release Notes: https://wiki.jriver.com/index.php/Release_Notes
What OS(s) and Version you are running:     Windows 10 Pro 64bit Version 2004 (OS Build 19041.572).
The JRMark score of the PC with an issue:    JRMark (version 26.0.52 64 bit): 3419
Important relevant info about your environment:     
  Using the HTPC as a MC Server & a Workstation as a MC Client plus some DLNA clients.
  Running JRiver for Android, JRemote2, Gizmo, & MO 4Media on a Sony Xperia XZ Premium Android 9.
  Playing video out to a Sony 65" TV connected via HDMI, playing digital audio out via motherboard sound card, PCIe TV tuner

vsolivas

  • Recent member
  • *
  • Posts: 6
Re: Request: m3u extended Playlist without path
« Reply #6 on: October 27, 2019, 04:58:40 pm »

I put the "." in the playlist path, and it put the playlist in the root of the device, but the path is still in front of the filename.
Logged

RoderickGI

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 8186
Re: Request: m3u extended Playlist without path
« Reply #7 on: October 27, 2019, 06:15:24 pm »

Oh well, over to someone from JRiver to comment or fix I guess.

They would have read this thread by now.
Logged
What specific version of MC you are running:MC27.0.27 @ Oct 27, 2020 and updating regularly Jim!                        MC Release Notes: https://wiki.jriver.com/index.php/Release_Notes
What OS(s) and Version you are running:     Windows 10 Pro 64bit Version 2004 (OS Build 19041.572).
The JRMark score of the PC with an issue:    JRMark (version 26.0.52 64 bit): 3419
Important relevant info about your environment:     
  Using the HTPC as a MC Server & a Workstation as a MC Client plus some DLNA clients.
  Running JRiver for Android, JRemote2, Gizmo, & MO 4Media on a Sony Xperia XZ Premium Android 9.
  Playing video out to a Sony 65" TV connected via HDMI, playing digital audio out via motherboard sound card, PCIe TV tuner

vsolivas

  • Recent member
  • *
  • Posts: 6
Re: Request: m3u extended Playlist without path
« Reply #8 on: October 27, 2019, 06:16:45 pm »

Thanks for your help!
Logged

vsolivas

  • Recent member
  • *
  • Posts: 6
Re: Request: m3u extended Playlist without path
« Reply #9 on: October 30, 2019, 12:45:26 am »

I found a work around. Here:  https://unix.stackexchange.com/questions/329939/processing-paths-in-m3u-file

You can set the Mac to run a shell script, either as a workflow or as an App or as a Folder Action or or as a Service or as a Script.

The Folder Actions function is spotty at best, so I'm using a script and FastScripts, a free app (for 2 scripts) that runs scripts.

The script I use is the following:

Open Apple Script Editor in Utilities Folder.

Type the following into the script editor:

set thePath to "Set/to/path/of/device"
do shell script "awk -F/ '!/^#/{$0=$NF}1' /Set/To/Path/of/device/Playlist.m3u > /Set/To/Path/of/device/testfile.tmp && mv /Set/To/Path/of/device/testfile.tmp /Set/To/Path/of/device/Playlist.m3u"

my settings are:

set thePath to "/Volumes/Walkman_SD/MUSIC/Podcasts/"
do shell script "awk -F/ '!/^#/{$0=$NF}1' /Volumes/Walkman_SD/MUSIC/Podcasts/Podcasts.m3u > /Volumes/Walkman_SD/MUSIC/Podcasts/testfile.tmp && mv /Volumes/Walkman_SD/MUSIC/Podcasts/testfile.tmp /Volumes/Walkman_SD/MUSIC/Podcasts/Podcasts.m3u"

Set to path is the playlist on your given device, which should be /Volumes/YourDevice/. I use a Sony Walkman nw-a35.

Save the script in your ~/Library/Scripts folder or /Library/Scripts/ folder if you want all users to access it. Then open up FastScripts and set the Script you save to a function button by clicking on "none" and pressing the function key you want to use. I use F14. Then when you save a playlist to your device, you can press F14 and the Playlist will automatically remove the path to the song files.


Or you could do a folder action or service (the services show up in the menubar of the Finder under the app name).

Open up Automator which is found in the Applications folder.  Choose New Document and select (app, workflow, folder action) Service.

Then go to Utilities on the left (you have to scroll down a bit), and drag "Run Shell Script" to the area on the right. This should open up a balloon where you can type in code. Be sure to select "as arguments" from the drop down on the upper right corner of the balloon (the default is "to stdin".

then copy the following code into the dialog box:

awk -F/ '!/^#/{$0=$NF}1' /Set/To/Path/of/device/Playlist.m3u > /path/of/device/testfile.tmp && mv /path/of/device/testfile.tmp /Set/To/Path/of/device/Playlist.m3u

setting the path to your device's path (/Volumes/YourDevice/Path/to/playlist/folder)

then save and look in the services menu on the menu dropdown for the app's name in the upper left of the screen. That should show your script in the services menu.

Like I said, the Folder Actions is spotty lately, but you can try it by creating a Folder Action in Automator the same way as the Service, and right clicking on the folder of your playlist in the /Volumes/YourDevice/ folder, then selecting Folder Actions Setup. This will show you the option to add folder actions to that folder. For more info, lookup Folder Actions Setup in your favorite search engine.

Logged
Pages: [1]   Go Up