From 837515213f367cd980314dbe4ac2595ef112d2f9 Mon Sep 17 00:00:00 2001 From: Monty Taylor Date: Wed, 18 Dec 2019 10:02:09 -0500 Subject: [PATCH] Don't index retired projects While they should just have a README, it's still a waste of energy for codesearch to index them in the first place. Remove the special condition for deb- repos - they are all retired. Change-Id: I60d90fccb607fcd48de42739188af5fb241ded7f --- jeepyb/cmd/create_hound_config.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/jeepyb/cmd/create_hound_config.py b/jeepyb/cmd/create_hound_config.py index 9f1275f..601ba74 100644 --- a/jeepyb/cmd/create_hound_config.py +++ b/jeepyb/cmd/create_hound_config.py @@ -36,18 +36,18 @@ GIT_PROTOCOL = os.environ.get('GIT_PROTOCOL', 'https://') def main(): registry = u.ProjectsRegistry(PROJECTS_YAML) - projects = [entry['project'] for entry in registry.configs_list] repos = {} - for project in projects: + for entry in registry.configs_list: + project = entry['project'] + # Don't bother indexing RETIRED projects. + if entry.get('description', '').startswith('RETIRED'): + continue + if 'retired.config' in entry.get('acl-config', ''): + continue # Ignore attic and stackforge, those are repos that are not # active anymore. if project.startswith(('openstack-attic', 'stackforge')): continue - # ignore deb- projects that are forks of other projects intended for - # internal debian packaging needs only and are generally not of - # interest to upstream developers - if os.path.basename(project).startswith('deb-'): - continue repos[project] = { 'url': "%(proto)s%(gitbase)s/%(project)s" % dict( proto=GIT_PROTOCOL, gitbase=GIT_SERVER, project=project),