Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Playlist import/export #447

Closed
OxygenCobalt opened this issue May 21, 2023 · 22 comments
Closed

Playlist import/export #447

OxygenCobalt opened this issue May 21, 2023 · 22 comments
Assignees
Labels
enhancement New feature or request music Related to music loading

Comments

@OxygenCobalt
Copy link
Owner

Split from #36.

@OxygenCobalt OxygenCobalt added enhancement New feature or request music Related to music loading labels May 21, 2023
@OxygenCobalt OxygenCobalt self-assigned this May 21, 2023
@OxygenCobalt OxygenCobalt mentioned this issue May 21, 2023
@KraXen72
Copy link

KraXen72 commented May 24, 2023

from #36:

  • ability to import m3u playlist
  • ability to export playlist as m3u (ideally with relative paths to the nearest shared parent folder, not absolutely to the sd card/internal storage)
  • remembering of m3u file which was imported & button to overwrite playlist contents with m3u contents (refresh) - link

stuff from #36 that might deserve it's own issue?:

@OxygenCobalt
Copy link
Owner Author

I'm actually unsure whether I'll immediately implement this as stateless import/export, or whether I will track the file URIs and update it that way. The latter is harder to manage and probably requires #322, so I think stateless import/export will come first.

@chxr16
Copy link

chxr16 commented Jun 6, 2023

Would it be possible to import playlists from Listenbrainz? The format is documented here, I think it would integrate nicely with the already existing MBID’s

@OxygenCobalt
Copy link
Owner Author

I can, but it would not have any internet fetching. You would need to download the .jspf file and then open it in Auxio @nzure.

@Mikaciu
Copy link

Mikaciu commented Jun 13, 2023

Would it be possible to be able to select the directory where the playlists are stored ?

@OxygenCobalt
Copy link
Owner Author

Playlists are stored in a database normally, but you will be able to export to any directory allowed by the file picker @Mikaciu.

@Wjxfi
Copy link

Wjxfi commented Jun 20, 2023

Great idea

@OxygenCobalt
Copy link
Owner Author

OxygenCobalt commented Aug 12, 2023

Update: Writing a M3U parser is stupid simple, so the backend of this can be easily done. I'm just stuck on the frontend, since I actually want to use menu/"speed dial" functionality so that the "create playlist" button as an option for importing. See the example(s) below:

image

tt8.mp4

This requires some custom view magic that will take a little bit, so I'm aiming for 3.3.0 for this.

@KraXen72
Copy link

  1. yes, m3u is a simple format (make sure to also take into account relative links)
  2. looks good!

@Wjxfi
Copy link

Wjxfi commented Aug 12, 2023

thank you, that's the most important thing to me! And I hope there won't be a problem with exporting a playlist with more than 1500 tracks on android! That would be great!

@OxygenCobalt
Copy link
Owner Author

OxygenCobalt commented Aug 12, 2023

There shouldn't be an issue @Wjxfi, but it might take a little while to import due to it's size.

@Wjxfi
Copy link

Wjxfi commented Aug 12, 2023

it's a good thing it is! I will gladly switch from retro music player to yours, as you will not have this error! Very much looking forward to the update! :)

@Wjxfi
Copy link

Wjxfi commented Sep 21, 2023

Hey! @OxygenCobalt Please :) waited so long

@OxygenCobalt
Copy link
Owner Author

OxygenCobalt commented Sep 21, 2023

Please be patient @Wjxfi. I am extremely busy with school and will not be able to do significant work on Auxio for a month or two.

@OxygenCobalt
Copy link
Owner Author

image

;)

@OxygenCobalt
Copy link
Owner Author

OxygenCobalt commented Dec 20, 2023

Screen_recording_20231220_132215.webm

Importing from this M3U file:

#EXTM3U
#PLAYLIST:Test Playlist
./Jon Hopkins - Immunity - 01 We Disappear.mp3
../Jon Hopkins - Immunity - 02 Open Eye Signal.mp3

Only relative paths are supported currently. I don't know how to go about absolute paths since android obfuscates the real path of something behind volume abstractions.

@OxygenCobalt
Copy link
Owner Author

NVM, absolute paths will be supported too, but under the assumption that they are relative to the volume of the M3U file.

Another additional assumption is the usage of unix-style "../dir/./file" type paths. If any of you use windows-style "C:\" paths, please let me know.

@chocmake
Copy link

chocmake commented Dec 23, 2023

Another additional assumption is the usage of unix-style "../dir/./file" type paths. If any of you use windows-style "C:" paths, please let me know.

foobar2000 exports such paths for its playlist M3U/M3U8 exports. I recall even old Blackberry's stock music player handling them fine[1], so they're presumably common enough.

[1] How it handled the paths was assuming the drive letter was the root of the exposed file system (so eg: M:\music was understood to be the music dir in the root of the directory tree as seen when file transfer is enabled).

@OxygenCobalt
Copy link
Owner Author

OxygenCobalt commented Dec 23, 2023

[1] How it handled the paths was assuming the drive letter was the root of the exposed file system (so eg: M:\music was understood to be the music dir in the root of the directory tree as seen when file transfer is enabled).

Alright, this sounds like what I can use for Auxio. I'm basically forced to assume the playlist volume is the same as the file volume.

@evanc577
Copy link

Will imported playlists automatically update when the m3u file is changed? If not automatically, an option to rescan and reimport all playlists would be good too.

@OxygenCobalt
Copy link
Owner Author

Sorry for the delay @evanc577. That's not planned for the MVP since it effectively requires #322 for the best results. Currently there's going to be an "Import" menu option that allows you to reimport a m3u file back into the playlist.

This feature is also basically done. There's some rough edges I need to resolve first regarding when names conflict, but otherwise it should arrive in the next release.

@OxygenCobalt
Copy link
Owner Author

Some of the other functionality mentioned here will be spun off into issues once I fully decide on doing them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request music Related to music loading
Projects
None yet
Development

No branches or pull requests

7 participants