Merge "Change manage-projects verbose logging to info"
diff --git a/jeepyb/cmd/manage_projects.py b/jeepyb/cmd/manage_projects.py
index 9d54f42..9393260 100644
--- a/jeepyb/cmd/manage_projects.py
+++ b/jeepyb/cmd/manage_projects.py
@@ -414,12 +414,12 @@
     # a local branch of, optionally prefixed with the
     # upstream prefix value
     for branch in git_command_output(
-            repo_path, "branch -a")[1].split():
+            repo_path, "branch -a")[1].split('\n'):
         if not branch.strip().startswith("remotes/upstream"):
             continue
         if "->" in branch:
             continue
-        local_branch = branch[len('remotes/upstream/'):]
+        local_branch = branch.split()[0][len('remotes/upstream/'):]
         if upstream_prefix:
             local_branch = "%s/%s" % (
                 upstream_prefix, local_branch)
diff --git a/jeepyb/cmd/update_bug.py b/jeepyb/cmd/update_bug.py
index 3868651..5a351e4 100644
--- a/jeepyb/cmd/update_bug.py
+++ b/jeepyb/cmd/update_bug.py
@@ -254,7 +254,7 @@
     Our regular expression is composed of three major parts:
     part1: Matches only at start-of-line (required). Optionally matches any
            word or hyphen separated words.
-    part2: Matches the words 'bug' or 'lp' on a word boundry (required).
+    part2: Matches the words 'bug' or 'lp' on a word boundary (required).
     part3: Matches a whole number (required).
 
     The following patterns will be matched properly:
diff --git a/jeepyb/cmd/welcome_message.py b/jeepyb/cmd/welcome_message.py
index e031ff7..b791088 100644
--- a/jeepyb/cmd/welcome_message.py
+++ b/jeepyb/cmd/welcome_message.py
@@ -136,7 +136,7 @@
     # Don't actually post the message
     parser.add_argument('--dryrun', dest='dryrun', action='store_true')
     parser.add_argument('--no-dryrun', dest='dryrun', action='store_false')
-    parser.add_argument('-v', dest='verbose', action='store_true',
+    parser.add_argument('-v', '--verbose', dest='verbose', action='store_true',
                         help='verbose output')
     parser.set_defaults(dryrun=False)
 
diff --git a/jeepyb/projects.py b/jeepyb/projects.py
index da898b9..64d00d9 100644
--- a/jeepyb/projects.py
+++ b/jeepyb/projects.py
@@ -55,66 +55,11 @@
 
 def is_direct_release(project_full_name):
     try:
-        direct = 'direct-release' in registry[project_full_name]['options']
-        # return ...
+        return 'direct-release' in registry[project_full_name]['options']
     except KeyError:
-        direct = False
-        # return False
-
-    return direct or _hardcoded_is_direct_release(project_full_name)
+        return False
 
 
 def docimpact_target(project_full_name):
-    return registry.get('docimpact-group', 'unknown')
-
-
-# The following functions should be deleted when projects.yaml will be updated
-
-def _hardcoded_is_direct_release(project_full_name):
-    """Test against a list of projects who directly release changes.
-
-    This function should be removed when projects.yaml will be updated.
-    To specify direct_release you just need add option 'direct_relese' to your
-    project declaration in projects.yaml
-
-    Example:
-        - project: some/project
-          options:
-            - direct-release
-          description: Best project ever.
-    """
-    return project_full_name in [
-        'openstack-dev/devstack',
-        'openstack-infra/askbot-theme',
-        'openstack-infra/config',
-        'openstack-infra/devstack-gate',
-        'openstack-infra/gerrit',
-        'openstack-infra/gerritbot',
-        'openstack-infra/gerritlib',
-        'openstack-infra/gitdm',
-        'openstack-infra/lodgeit',
-        'openstack-infra/meetbot',
-        'openstack-infra/nose-html-output',
-        'openstack-infra/publications',
-        'openstack-infra/reviewday',
-        'openstack-infra/statusbot',
-        'openstack/api-site',
-        'openstack/openstack-manuals',
-        'openstack/tempest',
-        'openstack/tripleo-heat-templates',
-        'openstack/tripleo-image-elements',
-        'openstack/tripleo-incubator',
-        'stackforge/cookbook-openstack-block-storage',
-        'stackforge/cookbook-openstack-common',
-        'stackforge/cookbook-openstack-compute',
-        'stackforge/cookbook-openstack-dashboard',
-        'stackforge/cookbook-openstack-identity',
-        'stackforge/cookbook-openstack-image',
-        'stackforge/cookbook-openstack-metering',
-        'stackforge/cookbook-openstack-network',
-        'stackforge/cookbook-openstack-object-storage',
-        'stackforge/cookbook-openstack-ops-database',
-        'stackforge/cookbook-openstack-ops-messaging',
-        'stackforge/cookbook-openstack-orchestration',
-        'stackforge/openstack-chef-repo',
-    ]
+    return registry.get_project_item(project_full_name, 'docimpact-group',
+                                     'unknown')
diff --git a/jeepyb/utils.py b/jeepyb/utils.py
index d010e3b..f92852e 100644
--- a/jeepyb/utils.py
+++ b/jeepyb/utils.py
@@ -51,5 +51,8 @@
     def __getitem__(self, item):
         return self.configs[item]
 
-    def get(self, item, default=None):
-        return self.configs.get(item, default)
+    def get_project_item(self, project, item, default=None):
+        if project in self.configs:
+            return self.configs[project].get(item, default)
+        else:
+            return default