mirror of
https://github.com/facebook/sapling.git
synced 2024-10-13 02:07:31 +03:00
config: register git.authors
This commit is contained in:
parent
44a24b6034
commit
febc5953e1
@ -64,6 +64,7 @@ def read_pkt_refs(proto):
|
|||||||
|
|
||||||
CONFIG_DEFAULTS = {
|
CONFIG_DEFAULTS = {
|
||||||
'git': {
|
'git': {
|
||||||
|
'authors': None,
|
||||||
'blockdotgit': True,
|
'blockdotgit': True,
|
||||||
'branch_bookmark_suffix': None,
|
'branch_bookmark_suffix': None,
|
||||||
'intree': None,
|
'intree': None,
|
||||||
|
@ -158,8 +158,9 @@ class GitHandler(object):
|
|||||||
|
|
||||||
def init_author_file(self):
|
def init_author_file(self):
|
||||||
self.author_map = {}
|
self.author_map = {}
|
||||||
if self.ui.config('git', 'authors'):
|
authors_path = compat.config(self.ui, 'string', 'git', 'authors')
|
||||||
with open(self.repo.wvfs.join(self.ui.config('git', 'authors'))) as f:
|
if authors_path:
|
||||||
|
with open(self.repo.wvfs.join(authors_path)) as f:
|
||||||
for line in f:
|
for line in f:
|
||||||
line = line.strip()
|
line = line.strip()
|
||||||
if not line or line.startswith('#'):
|
if not line or line.startswith('#'):
|
||||||
|
Loading…
Reference in New Issue
Block a user