mirror of
https://github.com/frappe/bench.git
synced 2024-11-11 15:51:03 +00:00
commit
4ff56f8dd7
@ -124,7 +124,7 @@ def get_current_version(app, bench='.'):
|
|||||||
def get_upstream_version(app, branch=None, bench='.'):
|
def get_upstream_version(app, branch=None, bench='.'):
|
||||||
repo_dir = get_repo_dir(app, bench=bench)
|
repo_dir = get_repo_dir(app, bench=bench)
|
||||||
if not branch:
|
if not branch:
|
||||||
branch = get_current_branch(app)
|
branch = get_current_branch(app, bench=bench)
|
||||||
try:
|
try:
|
||||||
contents = subprocess.check_output(['git', 'show', 'upstream/{branch}:setup.py'.format(branch=branch)], cwd=repo_dir, stderr=subprocess.STDOUT)
|
contents = subprocess.check_output(['git', 'show', 'upstream/{branch}:setup.py'.format(branch=branch)], cwd=repo_dir, stderr=subprocess.STDOUT)
|
||||||
except subprocess.CalledProcessError, e:
|
except subprocess.CalledProcessError, e:
|
||||||
|
@ -51,7 +51,8 @@ def init(path, apps_path=None, no_procfile=False, no_backups=False,
|
|||||||
|
|
||||||
if os.path.exists(path):
|
if os.path.exists(path):
|
||||||
print 'Directory {} already exists!'.format(path)
|
print 'Directory {} already exists!'.format(path)
|
||||||
sys.exit(1)
|
raise Exception("Site directory already exists")
|
||||||
|
# sys.exit(1)
|
||||||
|
|
||||||
os.mkdir(path)
|
os.mkdir(path)
|
||||||
for dirname in ('apps', 'sites', 'config', 'logs'):
|
for dirname in ('apps', 'sites', 'config', 'logs'):
|
||||||
|
Loading…
Reference in New Issue
Block a user