Comments (20)
Yeah that's what I was imagining. The *sonic
let the user choose which folders/libraries to view. Here's a screenshot from my Madsonic instance:
from gonic.
thanks too @djl this makes sense to me after seeing that screenshot
I've never even seen the ability to change music folders in the subsonic clients I use but that seems handy
from gonic.
There is also the issue of accessing symlinked paths on the host when you run gonic in docker. You can work around it by also mounting the paths that the symlinks point to, but it sort of defeats the point of symlinks, having to manage potentially many folders.
Whilst I don't divide my collection up in genre folders, I do have different folders like "new" (albums I just bought, but haven't listened a lot to yet), and albums then get moved to "unsorted" (the ones I liked and deemed were worth keeping), then I spend some time prettying up the folders/files/cover art/info and ultimately move them to "archive". Occasionally I may want to filter on that in my player.
from gonic.
hi all, I added some experimental support for this. if anyone is familiar with building from source and would like to test it, checkout the mockfs-scanner
branch
go install go.senan.xyz/gonic/cmd/gonic@mockfs-scanner
then multiple paths can be added by repeating the flag. eg
$ gonic \
-music-path /example/path/a \
-music-path /example/path/b \
-music-path /example/path/c
or if you're using env vars, try GONIC_MUSIC_PATH=/example/a,example/b
if you want to speed up the gonic scan after adding multiple folders for the first time, provide your original (non extra) music dir as the first argument.
this completely optional but can speed this up a bit if you like
from gonic.
It works!!! iSub now correctly displays all the music folders. Play:Sub and DSub keep working too.
Thanks for fixing it so quickly!
from gonic.
great to hear :) gonna merge that branch to master then. though not gonna release for a while because i still think it's a bit experimental. thanks for your help and let me know if something weird happens 👍
from gonic.
hey thank you :)
what I've been doing is making a gonic_music_dir
, pointing gonic at that, then symlinking all your multiple libraries into it
from gonic.
Hi, Sentriz.
Amazing project.
It would be nice assign libraries to user, and isolate the mp3 tree structure for each user.
Thanks!
from gonic.
👍
My use case is having folders/libraries for different types of audio (e.g. audiobooks, podcasts and music). Lumping these together, especially if your library is large, makes browsing specific types rather awkward.
I think this is the only feature I still miss from *sonic. I'd be willing to chip in on a bug/feature bounty if anyone wants to set it up :)
from gonic.
Thanks for this project Sentriz!!
I would love to see this implemented too.
from gonic.
hey thank you :)
what I've been doing is making a
gonic_music_dir
, pointing gonic at that, then symlinking all your multiple libraries into it
I don't really see a problem with this approach.
Can someone explain why they wouldn't want to do this? I think an implementation would have the similar effect, so I'm not unaware of the (potential) benefits.
It would be nice assign libraries to user, and isolate the mp3 tree structure for each user.
I think this would be the only benefit. Are there others?
from gonic.
I think this would be the only benefit. Are there others?
What I said above:
My use case is having folders/libraries for different types of audio (e.g. audiobooks, podcasts and music). Lumping these together, especially if your library is large, makes browsing specific types rather awkward.
I said "awkward" previously but in reality it's near impossible.
from gonic.
This is because you're envisioning these multiple folders getting read in would be in different views?
from gonic.
Ahh, right. Gotcha. Okay, seems interesting enough. Thanks for all the information.
from gonic.
My use case is similar to @djl but with genres.
For example, in Play:sub iphone client you can select the folder. I have my library organized by genre and I usually start a random playlist within that genre:
Trying to do the same but using the genre tags becomes quite a challenge. I have something like a thousand different tags...
from gonic.
Just did a quick check with play:Sub, iSub and DSub mobile apps.
Play:Sub and DSub looks ok, but with iSub there is an issue.
I added three paths and, in the case of iSub, although all the albums are available, when you are in the "folders" view, you can only select one of the three paths:
Not sure if this an issue on iSub side or the way gonic is doing the response for getMusicFolders
In any case, thanks for adding this feature!!
from gonic.
@cascooscuro thanks for trying it out :)
could you post the logs around the time of the iSub request to getMusicFolders? just interested in the query params that it's sending
also if you can, post the response from the request it is making? just a simple curl of the url it's requesting or put the url in your browser
from gonic.
this is the tcpdump for iSub (/rest/getMusicFolders.view?c=iSub&p=REDACTED&u=user&v=1.0.0
):
GET /rest/getMusicFolders.view?v=1.0.0&c=iSub&u=user&p=password HTTP/1.1
Host: 192.168.1.2:4747
Accept-Encoding: gzip, deflate
Accept: */*
User-Agent: iSub/413 CFNetwork/1240.0.4 Darwin/20.6.0
Accept-Language: en-us
Cache-Control: no-cache
Connection: keep-alive
HTTP/1.1 200 OK
Access-Control-Allow-Headers: Accept, Content-Type, Content-Length, Accept-Encoding, X-CSRF-Token, Authorization
Access-Control-Allow-Methods: POST, GET, OPTIONS, PUT, DELETE
Access-Control-Allow-Origin: *
Content-Type: application/xml
Date: Mon, 08 Nov 2021 16:11:23 GMT
Content-Length: 419
<subsonic-response status="ok" version="1.15.0" xmlns="http://subsonic.org/restapi" type="gonic">
<musicFolders>
<musicFolder id="/genre/folk" name="folk"></musicFolder>
<musicFolder id="/genre/blues" name="blues"></musicFolder>
<musicFolder id="/genre/opera" name="opera"></musicFolder>
</musicFolders>
</subsonic-response>
In this case iSub is only displaying "opera". It looks that it only sees the last musicfolder...
These are the logs for play:Sub app (/rest/getMusicFolders.view
). In this case the app shows the three paths correctly:
POST /rest/getMusicFolders.view HTTP/1.1
Host: 192.168.1.2:4747
Content-Type: application/x-www-form-urlencoded
Connection: keep-alive
Accept: */*
User-Agent: playSub/2021.2 (iPhone; iOS 14.8.1; Scale/2.00)
Accept-Language: en-US;q=1, es-ES;q=0.9
Accept-Encoding: gzip, deflate
Content-Length: 114
HTTP/1.1 200 OK
Access-Control-Allow-Headers: Accept, Content-Type, Content-Length, Accept-Encoding, X-CSRF-Token, Authorization
Access-Control-Allow-Methods: POST, GET, OPTIONS, PUT, DELETE
Access-Control-Allow-Origin: *
Content-Type: application/json
Date: Mon, 08 Nov 2021 16:19:49 GMT
Content-Length: 276
{"subsonic-response":{"status":"ok","version":"1.15.0","type":"gonic","musicFolders":{"musicFolder":[{"id":"/genre/folk","name":"folk"},{"id":"/genre/blues","name":"blues"},{"id":"/genre/opera","name":"opera"}]}}}
And finally for DSub (/rest/getMusicFolders.view?u=user&s=xxxxxxxxxxxxxxxxxxx&t=xxxxxxxxxxxxxxxxxxxxx&v=1.2.0&c=DSub
). In this case the app shows the three paths correctly:
GET /rest/getMusicFolders.view?u=user&s=xxxxxxxxxxxxxxxxxxxxxxxxx&t=xxxxxxxxxxxxxxxxxx&v=1.2.0&c=DSub HTTP/1.1
Accept-Encoding: gzip
User-Agent: DSub
Authorization: Basic xxxxxxxxxxxxxxxxxxxxxxxx==
Host: 192.168.1.2:4747
Connection: Keep-Alive
HTTP/1.1 200 OK
Access-Control-Allow-Headers: Accept, Content-Type, Content-Length, Accept-Encoding, X-CSRF-Token, Authorization
Access-Control-Allow-Methods: POST, GET, OPTIONS, PUT, DELETE
Access-Control-Allow-Origin: *
Content-Type: application/xml
Date: Mon, 08 Nov 2021 16:40:52 GMT
Content-Length: 419
<subsonic-response status="ok" version="1.15.0" xmlns="http://subsonic.org/restapi" type="gonic">
<musicFolders>
<musicFolder id="/genre/folk" name="folk"></musicFolder>
<musicFolder id="/genre/blues" name="blues"></musicFolder>
<musicFolder id="/genre/opera" name="opera"></musicFolder>
</musicFolders>
</subsonic-response>
from gonic.
@cascooscuro thank you kindly. very detailed :) I think the issue is that iSub expects the music_folder ID to be an int (true to the spec) where as other clients allow strings. let me see if I can make them ints
from gonic.
@cascooscuro how does the music-folder-id-ints
branch work for you? I did a bit of testing but I think most of the subsonic clients I use don't support musicFolders
from gonic.
Related Issues (20)
- FR: Import OPML
- jukebox locks and shuffling HOT 30
- Request: Show audio metadata in stream logs HOT 4
- FR: Use other sources for rich metadata
- Problem with cookie or specific proxy configuration needed HOT 2
- The page is not avail after the latest nightly pull
- Multiple genre/artist vorbis tags HOT 10
- Missing Internet Radio Stations HOT 9
- Last.fm artist doesn't exist, Gonic retries forever HOT 1
- Scrobbles not working HOT 7
- Including additional fields in Search3 for albums & tracks HOT 4
- Can't get "recently added" or "recently played" HOT 9
- doesn't compile on debian bookworm HOT 3
- Timeouts with the getGenres.view endpoint HOT 4
- config file flag "cdcmusic-path" not defined in flag set HOT 4
- Feature Request: Add option to keep the latest N episodes of a podcast
- Gonic fails to see all podcast episodes for Revolutions podcast HOT 3
- Feature Request: Let users ask the server to download individual podcast episodes HOT 2
- Episode status prevents playing HOT 3
- sync starred songs to last.fm HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gonic.