(Added) remove all option for groups.

This commit is contained in:
2023-03-23 16:59:42 +02:00
parent a1bcf572e1
commit cf88cdbc9f
2 changed files with 11 additions and 1 deletions
+8
View File
@@ -23,6 +23,7 @@ from typing import List, Optional
import typer
from tui_rsync.models.models import Group
from tui_rsync.models.models import all_group_labels
from tui_rsync.cli.groups.group_prompt import GroupPrompt
console = Console()
@@ -46,3 +47,10 @@ def one(
group = Group.get_group(group_label)
group.delete_instance()
@group_remove.command()
def all():
"""
[red b]Remove[/] [yellow] all existing groups[/].
"""
for label in all_group_labels().iterator():
one(label.label)