summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Shadura <andrew.shadura@collabora.co.uk>2016-11-14 10:25:13 +0000
committerThibault Saunier <thibault.saunier@osg.samsung.com>2016-11-14 08:59:00 -0300
commitdf7afa8b6a31faf5a8ef45deca3ac9eef81418e3 (patch)
tree68ee8ae0234644b149fbae37e14572ca368903e3
parent3fba85f01954fad7edee63637562e3721fc1ebaa (diff)
Parse the repository-local arcconfig (in .git/arc/config).
Signed-off-by: Andrew Shadura <andrew.shadura@collabora.co.uk> Differential Revision: https://phabricator.freedesktop.org/D1474
-rwxr-xr-xgit-phab7
1 files changed, 7 insertions, 0 deletions
diff --git a/git-phab b/git-phab
index 4683564..7c62245 100755
--- a/git-phab
+++ b/git-phab
@@ -396,6 +396,13 @@ Paste API Token from that page and press <enter>: """ % self.phabricator_uri)
"Make sure the current repository is properly configured "
"for phabricator")
+ path = os.path.join(self.repo.git_dir, 'arc', 'config')
+ try:
+ with open(path) as f:
+ self.arcconfig.update(json.load(f))
+ except FileNotFoundError as e:
+ pass
+
try:
self.phabricator_uri = self.arcconfig["phabricator.uri"]
except KeyError as e: