mirror of
https://gerrit.googlesource.com/git-repo
synced 2024-12-21 07:16:21 +00:00
Merge "Use 'stat' package instead of literals for mkdir()"
This commit is contained in:
commit
7601ee2608
3
repo
3
repo
@ -120,6 +120,7 @@ REPO_MAIN = S_repo + '/main.py' # main script
|
|||||||
import optparse
|
import optparse
|
||||||
import os
|
import os
|
||||||
import re
|
import re
|
||||||
|
import stat
|
||||||
import subprocess
|
import subprocess
|
||||||
import sys
|
import sys
|
||||||
import urllib2
|
import urllib2
|
||||||
@ -308,7 +309,7 @@ def SetupGnuPG(quiet):
|
|||||||
|
|
||||||
if not os.path.isdir(gpg_dir):
|
if not os.path.isdir(gpg_dir):
|
||||||
try:
|
try:
|
||||||
os.mkdir(gpg_dir, 0700)
|
os.mkdir(gpg_dir, stat.S_IRWXU)
|
||||||
except OSError as e:
|
except OSError as e:
|
||||||
print >>sys.stderr, \
|
print >>sys.stderr, \
|
||||||
'fatal: cannot make %s directory: %s' % (
|
'fatal: cannot make %s directory: %s' % (
|
||||||
|
Loading…
Reference in New Issue
Block a user