mirror of
https://github.com/frappe/bench.git
synced 2024-11-11 15:51:03 +00:00
changed parameter name
This commit is contained in:
parent
b005720a2b
commit
a65e9f09dc
@ -92,7 +92,7 @@ def remove_from_excluded_apps_txt(app, bench_path='.'):
|
||||
apps.remove(app)
|
||||
return write_excluded_apps_txt(apps, bench_path=bench_path)
|
||||
|
||||
def get_app(git_url, branch=None, bench_path='.', build_asset_files=True, verbose=False,
|
||||
def get_app(git_url, branch=None, bench_path='.', skip_assets=False, verbose=False,
|
||||
postprocess = True):
|
||||
# from bench.utils import check_url
|
||||
try:
|
||||
@ -137,7 +137,7 @@ def get_app(git_url, branch=None, bench_path='.', build_asset_files=True, verbos
|
||||
|
||||
if postprocess:
|
||||
|
||||
if build_asset_files:
|
||||
if not skip_assets:
|
||||
build_assets(bench_path=bench_path, app=app_name)
|
||||
conf = get_config(bench_path=bench_path)
|
||||
|
||||
@ -412,7 +412,7 @@ def get_major_version(version):
|
||||
def install_apps_from_path(path, bench_path='.'):
|
||||
apps = get_apps_json(path)
|
||||
for app in apps:
|
||||
get_app(app['url'], branch=app.get('branch'), bench_path=bench_path, build_asset_files=False)
|
||||
get_app(app['url'], branch=app.get('branch'), bench_path=bench_path, skip_assets=True)
|
||||
|
||||
def get_apps_json(path):
|
||||
if path.startswith('http'):
|
||||
|
@ -35,11 +35,11 @@ def init(path, apps_path, frappe_path, frappe_branch, no_procfile, no_backups,
|
||||
@click.argument('name', nargs=-1) # Dummy argument for backward compatibility
|
||||
@click.argument('git-url')
|
||||
@click.option('--branch', default=None, help="branch to checkout")
|
||||
@click.option('--skip-assets', is_flag=True, default=True, help="Do not build assets")
|
||||
def get_app(git_url, branch, name=None, skip_assets=True):
|
||||
@click.option('--skip-assets', is_flag=True, default=False, help="Do not build assets")
|
||||
def get_app(git_url, branch, name=None, skip_assets=False):
|
||||
"clone an app from the internet and set it up in your bench"
|
||||
from bench.app import get_app
|
||||
get_app(git_url, branch=branch, build_asset_files=skip_assets)
|
||||
get_app(git_url, branch=branch, skip_assets=skip_assets)
|
||||
|
||||
|
||||
@click.command('new-app')
|
||||
|
@ -72,7 +72,7 @@ def init(path, apps_path=None, no_procfile=False, no_backups=False,
|
||||
if not frappe_path:
|
||||
frappe_path = 'https://github.com/frappe/frappe.git'
|
||||
|
||||
get_app(frappe_path, branch=frappe_branch, bench_path=path, build_asset_files=False, verbose=verbose)
|
||||
get_app(frappe_path, branch=frappe_branch, bench_path=path, skip_assets=True, verbose=verbose)
|
||||
|
||||
if apps_path:
|
||||
install_apps_from_path(apps_path, bench_path=path)
|
||||
|
Loading…
Reference in New Issue
Block a user