@cms0/cms0 0.2.22 → 0.2.23
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/cjs/libs/cli/descriptor-writer.cjs +2 -0
- package/dist/cjs/libs/cli/paths.cjs +1 -0
- package/dist/esm/libs/cli/descriptor-writer.js +2 -0
- package/dist/esm/libs/cli/paths.js +1 -0
- package/dist/types/libs/cli/descriptor-writer.d.ts.map +1 -1
- package/dist/types/libs/cli/paths.d.ts +1 -0
- package/dist/types/libs/cli/paths.d.ts.map +1 -1
- package/package.json +2 -2
|
@@ -16,6 +16,7 @@ const FALLBACK_DESCRIPTOR = {
|
|
|
16
16
|
},
|
|
17
17
|
};
|
|
18
18
|
exports.FALLBACK_DESCRIPTOR = FALLBACK_DESCRIPTOR;
|
|
19
|
+
const LOCAL_GENERATED_STATE_GITIGNORE = "*\n";
|
|
19
20
|
function safeWrite(outputPath, output) {
|
|
20
21
|
try {
|
|
21
22
|
fs_1.default.mkdirSync(path_1.default.dirname(outputPath), { recursive: true });
|
|
@@ -45,6 +46,7 @@ function writeBundledDescriptorProjection(descriptor) {
|
|
|
45
46
|
}
|
|
46
47
|
function writeDescriptorFiles(resolved, descriptor, browserTarget = "sidecar") {
|
|
47
48
|
const localDescriptorOutputPaths = (0, paths_js_1.resolveLocalDescriptorOutputPaths)(resolved.projectRoot);
|
|
49
|
+
safeWrite(localDescriptorOutputPaths.gitignore, LOCAL_GENERATED_STATE_GITIGNORE);
|
|
48
50
|
safeWrite(localDescriptorOutputPaths.json, createJsonOutput(descriptor));
|
|
49
51
|
safeWrite(localDescriptorOutputPaths.cjsJs, createCjsOutput(descriptor));
|
|
50
52
|
writeBundledDescriptorProjection(browserTarget === "bundle" ? descriptor : FALLBACK_DESCRIPTOR);
|
|
@@ -56,6 +56,7 @@ const descriptorOutputPaths = {
|
|
|
56
56
|
exports.descriptorOutputPaths = descriptorOutputPaths;
|
|
57
57
|
function resolveLocalDescriptorOutputPaths(projectRoot) {
|
|
58
58
|
return {
|
|
59
|
+
gitignore: path_1.default.resolve(projectRoot, ".cms0/.gitignore"),
|
|
59
60
|
json: path_1.default.resolve(projectRoot, ".cms0/generated/schema-descriptor.json"),
|
|
60
61
|
cjsJs: path_1.default.resolve(projectRoot, ".cms0/generated/schema-descriptor.cjs"),
|
|
61
62
|
};
|
|
@@ -8,6 +8,7 @@ const FALLBACK_DESCRIPTOR = {
|
|
|
8
8
|
__cms0Fallback: true,
|
|
9
9
|
},
|
|
10
10
|
};
|
|
11
|
+
const LOCAL_GENERATED_STATE_GITIGNORE = "*\n";
|
|
11
12
|
function safeWrite(outputPath, output) {
|
|
12
13
|
try {
|
|
13
14
|
fs.mkdirSync(path.dirname(outputPath), { recursive: true });
|
|
@@ -37,6 +38,7 @@ function writeBundledDescriptorProjection(descriptor) {
|
|
|
37
38
|
}
|
|
38
39
|
function writeDescriptorFiles(resolved, descriptor, browserTarget = "sidecar") {
|
|
39
40
|
const localDescriptorOutputPaths = resolveLocalDescriptorOutputPaths(resolved.projectRoot);
|
|
41
|
+
safeWrite(localDescriptorOutputPaths.gitignore, LOCAL_GENERATED_STATE_GITIGNORE);
|
|
40
42
|
safeWrite(localDescriptorOutputPaths.json, createJsonOutput(descriptor));
|
|
41
43
|
safeWrite(localDescriptorOutputPaths.cjsJs, createCjsOutput(descriptor));
|
|
42
44
|
writeBundledDescriptorProjection(browserTarget === "bundle" ? descriptor : FALLBACK_DESCRIPTOR);
|
|
@@ -47,6 +47,7 @@ const descriptorOutputPaths = {
|
|
|
47
47
|
};
|
|
48
48
|
function resolveLocalDescriptorOutputPaths(projectRoot) {
|
|
49
49
|
return {
|
|
50
|
+
gitignore: path.resolve(projectRoot, ".cms0/.gitignore"),
|
|
50
51
|
json: path.resolve(projectRoot, ".cms0/generated/schema-descriptor.json"),
|
|
51
52
|
cjsJs: path.resolve(projectRoot, ".cms0/generated/schema-descriptor.cjs"),
|
|
52
53
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"descriptor-writer.d.ts","sourceRoot":"","sources":["../../../../src/libs/cli/descriptor-writer.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAI9C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAEjD,KAAK,uBAAuB,GAAG,SAAS,GAAG,QAAQ,CAAC;AAEpD,QAAA,MAAM,mBAAmB;;;;;;CAMf,CAAC;
|
|
1
|
+
{"version":3,"file":"descriptor-writer.d.ts","sourceRoot":"","sources":["../../../../src/libs/cli/descriptor-writer.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAI9C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAEjD,KAAK,uBAAuB,GAAG,SAAS,GAAG,QAAQ,CAAC;AAEpD,QAAA,MAAM,mBAAmB;;;;;;CAMf,CAAC;AA8CX,iBAAS,oBAAoB,CAC3B,QAAQ,EAAE,cAAc,EACxB,UAAU,EAAE,cAAc,EAC1B,aAAa,GAAE,uBAAmC,QAenD;AAED,OAAO,EAAE,mBAAmB,EAAE,oBAAoB,EAAE,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"paths.d.ts","sourceRoot":"","sources":["../../../../src/libs/cli/paths.ts"],"names":[],"mappings":"AA+CA,QAAA,MAAM,WAAW,QAAwB,CAAC;AAE1C,QAAA,MAAM,qBAAqB;;;;CAO1B,CAAC;AAEF,iBAAS,iCAAiC,CAAC,WAAW,EAAE,MAAM
|
|
1
|
+
{"version":3,"file":"paths.d.ts","sourceRoot":"","sources":["../../../../src/libs/cli/paths.ts"],"names":[],"mappings":"AA+CA,QAAA,MAAM,WAAW,QAAwB,CAAC;AAE1C,QAAA,MAAM,qBAAqB;;;;CAO1B,CAAC;AAEF,iBAAS,iCAAiC,CAAC,WAAW,EAAE,MAAM;;;;EAM7D;AAED,OAAO,EAAE,qBAAqB,EAAE,WAAW,EAAE,iCAAiC,EAAE,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cms0/cms0",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.23",
|
|
4
4
|
"description": "",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "restricted"
|
|
@@ -65,7 +65,7 @@
|
|
|
65
65
|
"chokidar": "^4.0.3",
|
|
66
66
|
"ts-morph": "^27.0.2",
|
|
67
67
|
"typescript": "^5.9.3",
|
|
68
|
-
"@cms0/shared": "0.2.
|
|
68
|
+
"@cms0/shared": "0.2.23"
|
|
69
69
|
},
|
|
70
70
|
"devDependencies": {
|
|
71
71
|
"@types/node": "^24.10.1",
|