utiller 1.0.197 → 1.0.198
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1730,13 +1730,22 @@ var NodeUtiller = /*#__PURE__*/function (_Utiller) {
|
|
|
1730
1730
|
return "";
|
|
1731
1731
|
}
|
|
1732
1732
|
|
|
1733
|
-
/** 因為code gen有很多要persistent, 沒有修改過{const edit = true}的index persist就不要理它 */
|
|
1733
|
+
/** 因為code gen有很多要js file要執行 persistent, 沒有修改過{const edit = true}的index persist就不要理它 */
|
|
1734
1734
|
}, {
|
|
1735
1735
|
key: "isFileEditSucceed",
|
|
1736
1736
|
value: function isFileEditSucceed(path) {
|
|
1737
|
-
|
|
1737
|
+
if (!this.isPathExist(path)) {
|
|
1738
|
+
return false;
|
|
1739
|
+
}
|
|
1740
|
+
var file = this.getPathInfo(path);
|
|
1741
|
+
var context = this.getFileContextInRaw(path);
|
|
1742
|
+
if (_lodash["default"].isEmpty(_lodash["default"].trim(context))) {
|
|
1743
|
+
this.appendInfo("74985465 path ".concat(file.path, " is empty file, file would not persist"));
|
|
1744
|
+
return false;
|
|
1745
|
+
}
|
|
1738
1746
|
try {
|
|
1739
|
-
var
|
|
1747
|
+
var stringOfHeadLine = _lodash["default"].head(context.split("\n"));
|
|
1748
|
+
var first = _lodash["default"].tail(stringOfHeadLine.split(" ")).join(" ");
|
|
1740
1749
|
var second = this.getNormalizedStringNotEndWith(first, ";");
|
|
1741
1750
|
var splits = second.split("=").map(function (each) {
|
|
1742
1751
|
return _lodash["default"].trim(each);
|
package/package.json
CHANGED