2
0
mirror of https://github.com/frappe/bench.git synced 2024-11-11 15:51:03 +00:00

chdir only if it exists

This commit is contained in:
Pratik Vyas 2014-12-03 10:34:23 +05:30
parent 0275a23e75
commit 09b0067992

View File

@ -63,7 +63,8 @@ def change_dir():
if os.path.exists(dir_path_file):
with open(dir_path_file) as f:
dir_path = f.read().strip()
os.chdir(dir_path)
if os.path.exists(dir_path):
os.chdir(dir_path)
def frappe(bench='.'):
f = get_frappe(bench=bench)