diff --git a/tools/project-creator/create_project.py b/tools/project-creator/create_project.py index 966baaeaff..be6e38babc 100755 --- a/tools/project-creator/create_project.py +++ b/tools/project-creator/create_project.py @@ -6,9 +6,9 @@ # define global variables PLATFORMS = { - "cpp" : ["ios", "android", "win32", "mac", "linux"], - "lua" : ["ios", "android", "win32", "mac", "linux"], - "javascript" : ["ios", "android", "win32", "mac"] + "cpp" : ["ios_mac", "android", "win32", "linux"], + "lua" : ["ios_mac", "android", "win32", "linux"], + "javascript" : ["ios_mac", "android", "win32"] } @@ -111,6 +111,14 @@ def processPlatformProjects(context, platform): java_package_path = os.path.join(*dst_pkg) + # rename files and folders + for item in data["rename"]: + tmp = item.replace("PACKAGE_PATH", java_package_path) + src = tmp.replace("PROJECT_NAME", context["src_project_name"]) + dst = tmp.replace("PROJECT_NAME", context["dst_project_name"]) + if os.path.exists(os.path.join(proj_path, src)): + os.rename(os.path.join(proj_path, src), os.path.join(proj_path, dst)) + # remove useless files and folders for item in data["remove"]: dst = item.replace("PROJECT_NAME", context["dst_project_name"])