mirror of
https://github.com/frappe/bench.git
synced 2025-01-09 16:36:25 +00:00
fix: git depth, fixed requirements (#845)
This commit is contained in:
parent
5c5993bf01
commit
ce6b4c8a11
@ -419,9 +419,9 @@ def get_apps_json(path):
|
|||||||
if path.startswith('http'):
|
if path.startswith('http'):
|
||||||
r = requests.get(path)
|
r = requests.get(path)
|
||||||
return r.json()
|
return r.json()
|
||||||
else:
|
|
||||||
with open(path) as f:
|
with open(path) as f:
|
||||||
return json.load(f)
|
return json.load(f)
|
||||||
|
|
||||||
def validate_branch():
|
def validate_branch():
|
||||||
for app in ['frappe', 'erpnext']:
|
for app in ['frappe', 'erpnext']:
|
||||||
|
@ -354,16 +354,16 @@ def check_git_for_shallow_clone():
|
|||||||
from .config.common_site_config import get_config
|
from .config.common_site_config import get_config
|
||||||
config = get_config('.')
|
config = get_config('.')
|
||||||
|
|
||||||
if config.get('release_bench'):
|
if config:
|
||||||
return False
|
if config.get('release_bench'):
|
||||||
|
return False
|
||||||
|
|
||||||
if not config.get('shallow_clone'):
|
if not config.get('shallow_clone'):
|
||||||
return False
|
return False
|
||||||
|
|
||||||
git_version = get_git_version()
|
git_version = get_git_version()
|
||||||
if git_version > 1.9:
|
if git_version > 1.9:
|
||||||
return True
|
return True
|
||||||
return False
|
|
||||||
|
|
||||||
def get_cmd_output(cmd, cwd='.'):
|
def get_cmd_output(cmd, cwd='.'):
|
||||||
try:
|
try:
|
||||||
@ -540,7 +540,7 @@ def update_json_file(filename, ddict):
|
|||||||
|
|
||||||
content.update(ddict)
|
content.update(ddict)
|
||||||
with open(filename, 'w') as f:
|
with open(filename, 'w') as f:
|
||||||
content = json.dump(content, f, indent=1, sort_keys=True)
|
json.dump(content, f, indent=1, sort_keys=True)
|
||||||
|
|
||||||
def drop_privileges(uid_name='nobody', gid_name='nogroup'):
|
def drop_privileges(uid_name='nobody', gid_name='nogroup'):
|
||||||
# from http://stackoverflow.com/a/2699996
|
# from http://stackoverflow.com/a/2699996
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
six
|
||||||
Click
|
Click
|
||||||
jinja2
|
jinja2
|
||||||
virtualenv
|
virtualenv
|
||||||
|
Loading…
Reference in New Issue
Block a user