forked from infra/ansible
updates+uptimes: Skip today backup in host output when today is identical.
Signed-off-by: James Antill <james@and.org>
This commit is contained in:
parent
ff798a8e5b
commit
0dd8bda7ed
1 changed files with 6 additions and 2 deletions
|
|
@ -1557,9 +1557,13 @@ def _cmd_host(args):
|
|||
last_name = "main"
|
||||
last_data = list(sorted(filter_name_datas(fname_datas(), hosts)))
|
||||
|
||||
hbackups = list(reversed(backups))
|
||||
if len(hbackups) > 1 and _backup_today_identical():
|
||||
hbackups = hbackups[1:]
|
||||
|
||||
_max_update(last_data)
|
||||
if not conf_fast_width_history:
|
||||
for backup in reversed(backups):
|
||||
for backup in hbackups:
|
||||
data = filter_name_datas(lines2datas(bfname2lines(backup)), hosts)
|
||||
data = list(sorted(data))
|
||||
_max_update(data)
|
||||
|
|
@ -1572,7 +1576,7 @@ def _cmd_host(args):
|
|||
done = False
|
||||
skipped_num = 0
|
||||
thostnum = 0
|
||||
for backup in reversed(backups):
|
||||
for backup in hbackups:
|
||||
data = filter_name_datas(lines2datas(bfname2lines(backup)), hosts)
|
||||
data = list(sorted(data))
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue