A plugin API to customize bliss
I would like to be able to do small customizations on the file organisation. It would be ideal if i could do so myself. having hooks and a documented api would enable me to do so. Also with a good system of plugins alternative solutions can be chosen by different people, just choose the plugins you want to get the desired behavior.
-
-
Christian L. commented
I totally would like to see this Feature coming.
1. My Suggestion is first make an API to add "Custom Rules" like in the Description from Dan Gravell.
This already should help a lot of People and to not invent the wheel new all the time there should be an option to share those rules with the community may with rating feature to faster find good rules.2. There should be a possibility to completely change some behaviors. to support eg. command line tools doing custom tagging -> the fixes costs for plugins like this can be calculated by previous tags to current tags state comparison or make them more expensive than 1 fix costs or only available for livetime fixes license.
-
This is a nice idea. Internally in bliss there is a rule language, used by some of the rules. It's of the form:
noncompliant because "[reason]" when [boolean condition] {
fixedby
[list of responses]
}The language itself is just the start, the language then needs objects and API a plugin writer can introspect. So here's a more complete example, the track artist rule (checks only one track artist in each album):
noncompliant because "Track artists differ" when album.trackArtists.size > 1 {
fixedby
com.elsten.bliss.music.policy.tagsync.trackartist.SetTrackArtistsInStorageNodesResponse(album,album.trackArtists),
if album.artist != mode(album.trackArtists) com.elsten.bliss.music.policy.tagsync.trackartist.SetTrackArtistsInStorageNodesResponse(album,album.artist)
} otherwise "All track artists are the same"Here you have the "album" object which contains all the info about a given album, according to bliss. The xResponses are essentially 'fixes' which may or may not run automatically.
If anyone has any feedback they're welcome to share.