mirror of
https://github.com/markqvist/Reticulum.git
synced 2024-11-22 21:50:18 +00:00
Added sort mode to rnstatus
This commit is contained in:
parent
575639b721
commit
fcdb455d73
@ -89,6 +89,8 @@ def program_setup(configdir, dispall=False, verbosity=0, name_filter=None, json=
|
|||||||
interfaces.sort(key=lambda i: i["incoming_announce_frequency"], reverse=not sort_reverse)
|
interfaces.sort(key=lambda i: i["incoming_announce_frequency"], reverse=not sort_reverse)
|
||||||
if sorting == "atx":
|
if sorting == "atx":
|
||||||
interfaces.sort(key=lambda i: i["outgoing_announce_frequency"], reverse=not sort_reverse)
|
interfaces.sort(key=lambda i: i["outgoing_announce_frequency"], reverse=not sort_reverse)
|
||||||
|
if sorting == "held":
|
||||||
|
interfaces.sort(key=lambda i: i["held_announces"], reverse=not sort_reverse)
|
||||||
|
|
||||||
|
|
||||||
for ifstat in interfaces:
|
for ifstat in interfaces:
|
||||||
@ -243,7 +245,7 @@ def main():
|
|||||||
"-s",
|
"-s",
|
||||||
"--sort",
|
"--sort",
|
||||||
action="store",
|
action="store",
|
||||||
help="sort interfaces by [traffic, rx, tx, announces, arx, atx, rate]",
|
help="sort interfaces by [rate, traffic, rx, tx, announces, arx, atx, held]",
|
||||||
default=None,
|
default=None,
|
||||||
type=str
|
type=str
|
||||||
)
|
)
|
||||||
|
Loading…
Reference in New Issue
Block a user