Plugins can now register .env settings

This commit is contained in:
Agate 2020-08-25 09:55:57 +02:00
parent f52ae5228f
commit ea83511d0a
4 changed files with 40 additions and 1 deletions

View file

@ -1,3 +1,13 @@
"""
A plugin that enables scrobbling to ListenBrainz and Last.fm.
If you're scrobbling to last.fm, you will need to create an `API account <https://www.last.fm/api/account/create>`_
and add two variables two your .env file:
- ``FUNKWHALE_PLUGIN_SCROBBLER_LASTFM_API_KEY=apikey``
- ``FUNKWHALE_PLUGIN_SCROBBLER_LASTFM_API_SECRET=apisecret``
"""
from config import plugins
PLUGIN = plugins.get_plugin_config(
@ -24,4 +34,8 @@ PLUGIN = plugins.get_plugin_config(
{"name": "username", "type": "text", "label": "Your scrobbler username"},
{"name": "password", "type": "password", "label": "Your scrobbler password"},
],
# settings=[
# {"name": "lastfm_api_key", "type": "text"},
# {"name": "lastfm_api_secret", "type": "text"},
# ]
)