diff --git a/manage/NovelManage.py b/manage/NovelManage.py index a8d679b..8b929ee 100644 --- a/manage/NovelManage.py +++ b/manage/NovelManage.py @@ -2,6 +2,9 @@ import sys, os import subprocess as xsub import time from typing import List +from parse.StoryMap import XAST_ParseTool, StoryMap, FragmentSlice, storyline_list2map +from parse.StorylineCmp import CmpTool, ModifyReason +from manage.MileStone import base_store_path, current_store_path def git_save(target_dir: str): @@ -42,4 +45,12 @@ if __name__ == "__main__": #wnss:-cmp if cmd_line == "wnss:-cmp": git_save(os.getcwd()) - nsc_compile(os.getcwd()) \ No newline at end of file + nsc_compile(os.getcwd()) + ast_old = XAST_ParseTool(base_store_path) + ast_new = XAST_ParseTool(current_store_path) + map_old = storyline_list2map(ast_old.story_list) + map_new = storyline_list2map(ast_new.story_list) + + cmp_tool = CmpTool() + all_changed = cmp_tool.graph_compare(map_new, map_old) + print(all_changed) \ No newline at end of file