mirror of
https://github.com/frappe/bench.git
synced 2025-01-10 09:02:10 +00:00
Fix backup for v5
This commit is contained in:
parent
f301ba49d2
commit
ae6d4eee99
@ -310,8 +310,11 @@ def update_requirements(bench='.'):
|
|||||||
exec_cmd("{pip} install -q -r {req_file}".format(pip=pip, req_file=req_file))
|
exec_cmd("{pip} install -q -r {req_file}".format(pip=pip, req_file=req_file))
|
||||||
|
|
||||||
def backup_site(site, bench='.'):
|
def backup_site(site, bench='.'):
|
||||||
|
if FRAPPE_VERSION == 4:
|
||||||
exec_cmd("{frappe} --backup {site}".format(frappe=get_frappe(bench=bench), site=site),
|
exec_cmd("{frappe} --backup {site}".format(frappe=get_frappe(bench=bench), site=site),
|
||||||
cwd=os.path.join(bench, 'sites'))
|
cwd=os.path.join(bench, 'sites'))
|
||||||
|
else:
|
||||||
|
run_frappe_cmd('--site {site} backup'.format(site=site), bench=bench)
|
||||||
|
|
||||||
def backup_all_sites(bench='.'):
|
def backup_all_sites(bench='.'):
|
||||||
for site in get_sites(bench=bench):
|
for site in get_sites(bench=bench):
|
||||||
|
Loading…
Reference in New Issue
Block a user