Merge "Updated code review timeline"
diff --git a/jeepyb/cmd/close_pull_requests.py b/jeepyb/cmd/close_pull_requests.py
index c1b6a1f..b49bac3 100644
--- a/jeepyb/cmd/close_pull_requests.py
+++ b/jeepyb/cmd/close_pull_requests.py
@@ -38,6 +38,7 @@
# [github]
# oauth_token = GITHUB_OAUTH_TOKEN
+import argparse
import ConfigParser
import github
import logging
@@ -64,6 +65,22 @@
format='%(asctime)-6s: %(name)s - %(levelname)s'
' - %(message)s')
+ parser = argparse.ArgumentParser()
+ parser.add_argument('--message-file', dest='message_file', default=None,
+ help='The close pull request message')
+
+ args = parser.parse_args()
+
+ if args.message_file:
+ try:
+ with open(args.message_file, 'r') as _file:
+ pull_request_text = _file.read()
+ except (OSError, IOError):
+ log.exception("Could not open close pull request message file")
+ raise
+ else:
+ pull_request_text = MESSAGE
+
GITHUB_SECURE_CONFIG = os.environ.get('GITHUB_SECURE_CONFIG',
'/etc/github/github.secure.config')
@@ -113,7 +130,7 @@
headers={},
attributes=issue_data,
completed=True)
- issue.create_comment(MESSAGE % vars)
+ issue.create_comment(pull_request_text % vars)
req.edit(state="closed")
if __name__ == "__main__":
diff --git a/setup.cfg b/setup.cfg
index a2a775d..12e056e 100644
--- a/setup.cfg
+++ b/setup.cfg
@@ -5,7 +5,7 @@
README.rst
author = OpenStack Infrastructure Team
author-email = openstack-infra@lists.openstack.org
-home-page = http://ci.openstack.org/
+home-page = http://docs.openstack.org/infra/system-config/
classifier =
Intended Audience :: Information Technology
Intended Audience :: System Administrators