Server instanses counter

This commit is contained in:
localhost_frssoft 2022-11-28 02:48:22 +03:00
parent 67aa2257cb
commit bd095da8ac

View File

@ -74,8 +74,11 @@ def main():
if selected == 'Switch instance':
with open('config.json', 'rt') as f:
conf = json.loads(f.read())
list_instances = conf.get('public_list_instances') + settings.get_new_funkwhale_servers()
instance = fzf.prompt(list_instances, '--header \'Select instance\'')[0]
public_server_list_instances = settings.get_new_funkwhale_servers()
new_ins_count = len(settings.get_new_funkwhale_servers())
list_instances = conf.get('public_list_instances') + public_server_list_instances
instance = fzf.prompt(list_instances,
'--header='+quote(f'Select instance\nServer instances: +{new_ins_count}'))[0]
select_instance(instance)
if selected == 'Sign in':
print(f'''