[sysadmin-bin] better names for various sections
- From: Olav Vitters <ovitters src gnome org>
- To: gnome-sysadmin gnome org,commits-list gnome org
- Subject: [sysadmin-bin] better names for various sections
- Date: Sat, 2 Aug 2014 22:34:08 +0000 (UTC)
commit c96bc51cae3f945866320ae5523a19e9b97f254e
Author: Olav Vitters <olav vitters nl>
Date: Sun Aug 3 00:33:31 2014 +0200
better names for various sections
git/build-repo-list | 35 +++++++++++++++++++++--------------
1 files changed, 21 insertions(+), 14 deletions(-)
---
diff --git a/git/build-repo-list b/git/build-repo-list
index 37b13a0..f81a9b1 100755
--- a/git/build-repo-list
+++ b/git/build-repo-list
@@ -15,28 +15,35 @@ GNOME = "http://api.gnome.org/doap-extensions#"
# This is what GIT writes by default, we replace it with something better
NO_DESCRIPTION = 'Unnamed repository; edit this file to name it for gitweb.'
-sectionlist = ('Core', 'Core Apps', 'Apps', 'Infrastructure', 'Other',
- # old and deprecated:
- 'Administration Tools', 'Bindings', 'Desktop', 'Development Tools',
- 'Platform', 'Productivity Tools',
- # always at end:
- 'Deprecated', 'Archived')
+sectionlist = (
+ 'core', 'core-apps', 'apps', 'infrastructure', 'other',
+ # old and deprecated:
+ 'admin', 'bindings', 'desktop', 'development',
+ 'platform', 'productivity',
+ # always at end:
+ 'deprecated', 'archived'
+)
+
sectionmap = {
- 'core': 'Core',
- 'core-apps': 'Core Apps',
- 'apps': 'Apps',
+ 'core': 'Core Suite',
+ 'core-apps': 'Core Apps Suite',
+ 'apps': 'Apps Suite',
'admin': 'Administration Tools',
+ 'archived': 'Archived',
'bindings': 'Bindings',
'deprecated': 'Deprecated',
'desktop': 'Desktop',
'development': 'Development Tools',
'infrastructure': 'Infrastructure',
'platform': 'Platform',
- 'productivity': 'Productivity Tools'
- }
+ 'productivity': 'Productivity Tools',
+ 'other': 'Not part of a suite',
+}
+DEFAULT_SECTION = sectionmap['other']
+
sections = {}
for section in sectionlist:
- sections[section] = []
+ sections[sectionmap[section]] = []
class Repo:
def __init__(self, repopath):
@@ -66,7 +73,7 @@ class Repo:
section = None
if os.path.isfile(section_file):
section = open(section_file).readline().strip()
- self.section = sectionmap.get(section, 'Other')
+ self.section = sectionmap.get(section, DEFAULT_SECTION)
prog_file = os.path.join(repopath, 'programming-languages')
prog = []
@@ -102,7 +109,7 @@ def iter_repos (paths, repo_func, include_pending=True):
sections[repo.section].append(repo)
for section in sectionlist:
- for repo in sorted(sections[section], sort_repos):
+ for repo in sorted(sections[sectionmap[section]], sort_repos):
repo_func(repo)
def output_cgit(repo):
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]