Skip to content

Commit

Permalink
Format SCsub.
Browse files Browse the repository at this point in the history
  • Loading branch information
fire committed Aug 20, 2023
1 parent 007e94a commit dfbdf57
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions SCsub
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,9 @@ def dump_text_file_to_cpp(file):
if JS_ENGINE == "quickjs":
import generate_builtin_api

generate_builtin_api.generate_api_json(os.path.join(GetLaunchDir(), "modules", os.path.basename(os.getcwd())))
generate_builtin_api.generate_api_json(
os.path.join(GetLaunchDir(), "modules", os.path.basename(os.getcwd()))
)
import thirdparty.quickjs.builtin_binding_generator

thirdparty.quickjs.builtin_binding_generator.generate_builtin_bindings()
Expand All @@ -51,8 +53,10 @@ if JS_ENGINE == "quickjs":
quickjs_env.Append(CPPPATH=["thirdparty/quickjs"])
quickjs_env.disable_warnings()
if TOOLS:
quickjs_env.add_source_files(env.modules_sources, "tools/editor_tools.cpp")
quickjs_env.add_source_files(env.modules_sources, "thirdparty/quickjs/quickjs_builtin_binder.gen.cpp")
quickjs_env.add_source_files(env.modules_sources, "tools/editor_tools.cpp")
quickjs_env.add_source_files(
env.modules_sources, "thirdparty/quickjs/quickjs_builtin_binder.gen.cpp"
)
quickjs_env.add_source_files(env.modules_sources, "thirdparty/quickjs/*.cpp")
quickjs_env.add_source_files(env.modules_sources, "thirdparty/quickjs/quickjs/*.c")

Expand All @@ -71,9 +75,7 @@ sources = [
]

if TOOLS:
base_text = (
'/* THIS FILE IS GENERATED DO NOT EDIT */\n#include "editor_tools.h"\nString JavaScriptPlugin::{} = \n{};'
)
base_text = '/* THIS FILE IS GENERATED DO NOT EDIT */\n#include "editor_tools.h"\nString JavaScriptPlugin::{} = \n{};'
tool_fns = {
"tools/godot.d.ts.gen.cpp": (
"BUILTIN_DECLARATION_TEXT",
Expand Down

0 comments on commit dfbdf57

Please sign in to comment.