zen-fs-config 0.3.28 → 0.3.29
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.
- package/dist/index.js +1 -8
- package/dist/index.mjs +1 -8
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -991,14 +991,10 @@ var ConfigRepo = class {
|
|
|
991
991
|
for (const part of parts) {
|
|
992
992
|
current += `/${part}`;
|
|
993
993
|
const exists = await this.fullFS.exists(current);
|
|
994
|
-
console.log(`[ensureDir] ${current} exists=${exists}`);
|
|
995
994
|
if (!exists) {
|
|
996
995
|
try {
|
|
997
|
-
console.log(`[ensureDir] mkdir(${current})`);
|
|
998
996
|
await this.fullFS.mkdir(current);
|
|
999
|
-
|
|
1000
|
-
} catch (err) {
|
|
1001
|
-
console.error(`[ensureDir] mkdir(${current}) FAILED:`, err.message);
|
|
997
|
+
} catch {
|
|
1002
998
|
}
|
|
1003
999
|
}
|
|
1004
1000
|
}
|
|
@@ -1029,16 +1025,13 @@ var ConfigRepo = class {
|
|
|
1029
1025
|
return results;
|
|
1030
1026
|
}
|
|
1031
1027
|
async writeMetaFile(path, data) {
|
|
1032
|
-
console.log(`[writeMetaFile] ${path}, ensuring dir...`);
|
|
1033
1028
|
await this.ensureDir(path);
|
|
1034
1029
|
const bytes = new TextEncoder().encode(JSON.stringify(data, null, 2));
|
|
1035
|
-
console.log(`[writeMetaFile] ${path}, writing ${bytes.length} bytes...`);
|
|
1036
1030
|
await this.cachedFS.writeFile(path, bytes);
|
|
1037
1031
|
const author = `${this.appId}/${this.nodeId}`;
|
|
1038
1032
|
const version = await incrementVersion(this.fullFS, path, bytes, author);
|
|
1039
1033
|
await this.ensureDir(versionPathFor(path));
|
|
1040
1034
|
await writeVersion(this.fullFS, versionPathFor(path), version);
|
|
1041
|
-
console.log(`[writeMetaFile] ${path} done (version=${version.version})`);
|
|
1042
1035
|
}
|
|
1043
1036
|
async readMetaFile(path) {
|
|
1044
1037
|
try {
|
package/dist/index.mjs
CHANGED
|
@@ -942,14 +942,10 @@ var ConfigRepo = class {
|
|
|
942
942
|
for (const part of parts) {
|
|
943
943
|
current += `/${part}`;
|
|
944
944
|
const exists = await this.fullFS.exists(current);
|
|
945
|
-
console.log(`[ensureDir] ${current} exists=${exists}`);
|
|
946
945
|
if (!exists) {
|
|
947
946
|
try {
|
|
948
|
-
console.log(`[ensureDir] mkdir(${current})`);
|
|
949
947
|
await this.fullFS.mkdir(current);
|
|
950
|
-
|
|
951
|
-
} catch (err) {
|
|
952
|
-
console.error(`[ensureDir] mkdir(${current}) FAILED:`, err.message);
|
|
948
|
+
} catch {
|
|
953
949
|
}
|
|
954
950
|
}
|
|
955
951
|
}
|
|
@@ -980,16 +976,13 @@ var ConfigRepo = class {
|
|
|
980
976
|
return results;
|
|
981
977
|
}
|
|
982
978
|
async writeMetaFile(path, data) {
|
|
983
|
-
console.log(`[writeMetaFile] ${path}, ensuring dir...`);
|
|
984
979
|
await this.ensureDir(path);
|
|
985
980
|
const bytes = new TextEncoder().encode(JSON.stringify(data, null, 2));
|
|
986
|
-
console.log(`[writeMetaFile] ${path}, writing ${bytes.length} bytes...`);
|
|
987
981
|
await this.cachedFS.writeFile(path, bytes);
|
|
988
982
|
const author = `${this.appId}/${this.nodeId}`;
|
|
989
983
|
const version = await incrementVersion(this.fullFS, path, bytes, author);
|
|
990
984
|
await this.ensureDir(versionPathFor(path));
|
|
991
985
|
await writeVersion(this.fullFS, versionPathFor(path), version);
|
|
992
|
-
console.log(`[writeMetaFile] ${path} done (version=${version.version})`);
|
|
993
986
|
}
|
|
994
987
|
async readMetaFile(path) {
|
|
995
988
|
try {
|