sentriz / gonic

music streaming server / free-software subsonic server API implementation
ircs://irc.libera.chat/#gonic
GNU General Public License v3.0
1.62k stars 115 forks source link

Request: better playlist portability #529

Open 0chroma opened 4 months ago

0chroma commented 4 months ago

I like that gonic stores everything as files, but the playlist files it writes use absolute paths, which might change between machines.

It'd be nice if you could specify a custom prefix. For example, I have the following directory structure:

Music/
├── Playlists/
│   └── 1
│       └── playlist1.m3u8
├── Podcasts/
└── Artist 1
       └── Album 1
           ├── 01.song.flac
           └── folder.jpg

It would be nice if I could set the prefix to be ../../ in this case so that the playlists would work even if the absolute path of Music/ changed. The default prefix could just be GONIC_MUSIC_PATH in order to stay consistent with existing behavior.