mirror of
https://gitea.phreedom.club/localhost_frssoft/funkwlmpv
synced 2024-11-15 03:33:01 +00:00
Add new instance via menu
This commit is contained in:
parent
25217ae98f
commit
808e94a8ac
@ -115,7 +115,8 @@ def instances_menu(fetch_manually=False, fetch_node_info=False):
|
||||
list_instances = fetch_instances_nodeinfo_and_avalaibility([instance.split('|')[0].strip() for instance in list_instances.keys()])
|
||||
settings.set_config('public_list_instances_extended', list_instances)
|
||||
map_in_extend_mode = '\nmap: instance | anonymousCanListen | tracks'
|
||||
instance_menu_selector = ['Fetch new instances',
|
||||
instance_menu_selector = ['Add new instance',
|
||||
'Fetch new instances',
|
||||
'Fetch nodeinfo and avalaibility',
|
||||
'Remove unreachible instances',
|
||||
'Shuffle']
|
||||
@ -128,6 +129,11 @@ def instances_menu(fetch_manually=False, fetch_node_info=False):
|
||||
return
|
||||
else:
|
||||
instance = instance[0].split('|')[0].strip()
|
||||
if instance == 'Add new instance':
|
||||
new = input('example.com\n').strip()
|
||||
list_instances[new] = 'added by user'
|
||||
settings.set_config('public_list_instances_extended', list_instances)
|
||||
instance = new
|
||||
if instance == 'Fetch new instances':
|
||||
return instances_menu(fetch_manually=True)
|
||||
if instance == 'Fetch nodeinfo and avalaibility':
|
||||
|
Loading…
Reference in New Issue
Block a user