|
|
|
|
|
|
#!/usr/bin/python -B |
|
|
|
import os |
|
|
|
import json |
|
|
|
import shutil |
|
|
|
import textwrap |
|
|
|
|
|
|
|
sub_packages = {} |
|
|
|
sub_package_folders = {} |
|
|
|
publish_order = [] |
|
|
|
|
|
|
|
def packages_list(): |
|
|
|
return [ |
|
|
|
|
|
|
# helper function for preparations of tests |
|
|
|
def copy_path_to_project(path, repo_path, project_path, logger): |
|
|
|
logger.info("Copying {}".format(path)) |
|
|
|
shutil.copytree(os.path.join(repo_path, path), os.path.join(project_path, "Assets", os.path.basename(path))) |
|
|
|
|
|
|
|
def copy_file_to_project(path, repo_path, project_path, logger): |
|
|
|
logger.info("Copying {}".format(path)) |
|
|
|
shutil.copy(os.path.join(repo_path, path), os.path.join(project_path, "Assets", path)) |
|
|
|
|
|
|
|
copy_path_to_project(os.path.join("MaterialGraphProject", "Assets", "NewNodes"), repo_path, project_path, logger) |
|
|
|
copy_path_to_project(os.path.join("MaterialGraphProject", "Assets", "TestAssets"), repo_path, project_path, logger) |
|
|
|
copy_path_to_project(os.path.join("MaterialGraphProject", "Assets", "UnityShaderEditor", "Editor", "Testing"), repo_path, project_path, logger) |
|
|
|
import unity_package_build |
|
|
|
unity_package_build.copy_path_to_project(os.path.join("MaterialGraphProject", "Assets", "NewNodes"), repo_path, project_path, logger) |
|
|
|
unity_package_build.copy_path_to_project(os.path.join("MaterialGraphProject", "Assets", "TestAssets"), repo_path, project_path, logger) |
|
|
|
unity_package_build.copy_path_to_project(os.path.join("MaterialGraphProject", "Assets", "UnityShaderEditor", "Editor", "Testing"), repo_path, project_path, logger) |
|
|
|
|
|
|
|
if __name__ == "__main__": |
|
|
|
import sys |
|
|
|