Add gerritx project infrastructure.
Add all of the support files needed for this to be a project.
Also, fix pep8 and pyflakes errors.
diff --git a/gerritx/cmd/notify_impact.py b/gerritx/cmd/notify_impact.py
old mode 100755
new mode 100644
index 5c8ba8c..559fd7f
--- a/gerritx/cmd/notify_impact.py
+++ b/gerritx/cmd/notify_impact.py
@@ -34,6 +34,7 @@
%s
"""
+
def process_impact(git_log, args):
"""Notify mail list of impact"""
email_content = EMAIL_TEMPLATE % (args.impact, args.change_url, git_log)
@@ -48,10 +49,12 @@
args.dest_address, msg.as_string())
s.quit()
+
def impacted(git_log, impact_string):
"""Determine if a changes log indicates there is an impact"""
return re.search(impact_string, git_log, re.IGNORECASE)
+
def extract_git_log(args):
"""Extract git log of all merged commits"""
cmd = ['git',
@@ -86,7 +89,3 @@
# Process impacts found in git log
if impacted(git_log, args.impact):
process_impact(git_log, args)
-
-
-if __name__ == '__main__':
- main()