@@ -65,16 +65,16 @@ def _run_vite_build(app_name: str, components: set[str], out_dir: str, base: str
6565 popen (command , cwd = studio_app_path , env = get_node_env (), raise_err = True )
6666
6767
68- def build_all_standard_apps ( app_filter : str | None = None ) -> None :
68+ def build_standard_apps ( app : str | None = None ) -> None :
6969 """Scan all apps on the bench for studio/ folders and build each exported app.
7070
7171 This function works without DB access — it reads component data from
7272 exported JSON files on disk.
7373
7474 Args:
75- app_filter : Only build studio apps exported to this specific frappe app
75+ app : Only build studio apps exported to this specific frappe app
7676 """
77- apps = [app_filter ] if app_filter else frappe .get_all_apps ()
77+ apps = [app ] if app else frappe .get_all_apps ()
7878
7979 for app in apps :
8080 studio_folder = frappe .get_app_source_path (app , "studio" )
@@ -246,12 +246,8 @@ def _add_block_components(
246246 _add_block_components (slot_child , components , studio_component_blocks , non_vue_components )
247247
248248
249- def after_build (app_name : str | None = None ) -> None :
250- """Hook called after `bench build`. Builds all standard studio apps.
251-
252- This runs without site context (no DB), so it only handles
253- standard (exported) apps by reading from disk.
254- """
255- click .echo (click .style ("\n ⚡ Building Studio Apps..." , fg = "cyan" ))
256- build_all_standard_apps (app_filter = app_name )
257- click .echo (click .style ("✔ Studio Apps built" , fg = "green" ))
249+ def after_build () -> None :
250+ """Hook called after `bench build`. Builds all standard studio apps"""
251+ click .echo (click .style ("\n Building Studio Apps..." , fg = "cyan" ))
252+ build_standard_apps ()
253+ click .echo (click .style ("Studio Apps built" , fg = "green" ))
0 commit comments