checkupdates: no need to sort tags if len()<=5

This commit is contained in:
Daniel Martí 2015-10-27 13:41:09 +01:00
parent 37b13c37d5
commit ece3317be0

View file

@ -134,7 +134,7 @@ def check_tags(app, pattern):
tags = [tag for tag in tags if pat.match(tag)] tags = [tag for tag in tags if pat.match(tag)]
logging.debug("Matching tags: " + ','.join(tags)) logging.debug("Matching tags: " + ','.join(tags))
if repotype in ('git',): if len(tags) > 5 and repotype in ('git',):
tags = vcs.latesttags(tags, 5) tags = vcs.latesttags(tags, 5)
logging.debug("Latest tags: " + ','.join(tags)) logging.debug("Latest tags: " + ','.join(tags))