Python3
This commit is contained in:
parent
35a9a8a8ba
commit
a5c8c2022b
2 changed files with 6 additions and 3 deletions
|
@ -87,8 +87,11 @@ def init_admin_repository(
|
||||||
# ConfigParser does not guarantee order, so jump through hoops
|
# ConfigParser does not guarantee order, so jump through hoops
|
||||||
# to make sure [gitosis] is first
|
# to make sure [gitosis] is first
|
||||||
cfg_file = StringIO()
|
cfg_file = StringIO()
|
||||||
print >>cfg_file, '[gitosis]'
|
print('[gitosis]', file=cfg_file)
|
||||||
print >>cfg_file
|
#print('', end="", file=cfg_file)
|
||||||
|
|
||||||
|
#print >>cfg_file, '[gitosis]'
|
||||||
|
#print >>cfg_file
|
||||||
cfg = RawConfigParser()
|
cfg = RawConfigParser()
|
||||||
cfg.add_section('group gitosis-admin')
|
cfg.add_section('group gitosis-admin')
|
||||||
cfg.set('group gitosis-admin', 'members', user)
|
cfg.set('group gitosis-admin', 'members', user)
|
||||||
|
|
|
@ -185,7 +185,7 @@ def has_initial_commit(git_dir):
|
||||||
stdout=subprocess.PIPE,
|
stdout=subprocess.PIPE,
|
||||||
close_fds=True,
|
close_fds=True,
|
||||||
)
|
)
|
||||||
got = child.stdout.read()
|
got = child.stdout.read().decode('utf-8')
|
||||||
returncode = child.wait()
|
returncode = child.wait()
|
||||||
if returncode != 0:
|
if returncode != 0:
|
||||||
raise GitRevParseError('exit status %d' % returncode)
|
raise GitRevParseError('exit status %d' % returncode)
|
||||||
|
|
Loading…
Reference in a new issue