Ejemplo n.º 1
0
        private void UpdateReleasePath()
        {
            string first   = "Version(Alpha) ";
            string end     = ".unitypackage)";
            string replace = "Version(Alpha) {VER} - [XTween_{VER}.unitypackage](https://github.com/Toki-Labs/XTween/raw/master/Bin/XTween_{VER}.unitypackage)";

            replace = replace.Replace("{VER}", Data.version);
            string filePath = XTweenEditorManager.AbsPath + "/README.md";
            string content  = XTweenEditorManager.ReadText(filePath);

            content = ReplaceTargetStringInContent(first, end, replace, content);
            XTweenEditorManager.WriteText(filePath, content);

            first   = "<!--Version Start";
            end     = "Version End-->";
            replace =
                "<!--Version Start-->\n" +
                "<p>Version(Alpha) " + Data.version + " - <a href=\"https://github.com/Toki-Labs/XTween/raw/master/Bin/XTween_" + Data.version + ".unitypackage\">XTween_" + Data.version + ".unitypackage</a></p>\n" +
                "<!--Version End-->";
            filePath = XTweenEditorManager.AbsPath + "/Export/index.html";
            content  = XTweenEditorManager.ReadText(filePath);
            content  = ReplaceTargetStringInContent(first, end, replace, content);
            XTweenEditorManager.WriteText(filePath, content);
        }
Ejemplo n.º 2
0
        public void Save()
        {
            string jsonStr = JsonUtility.ToJson(this._data);

            XTweenEditorManager.WriteText(this.JsonPath, jsonStr);
        }