@lightdash/cli 3.381.2 → 3.381.3
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"loader.d.ts","sourceRoot":"","sources":["../../src/lightdash/loader.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,wBAAwB,EAAE,MAAM,mBAAmB,CAAC;
|
|
1
|
+
{"version":3,"file":"loader.d.ts","sourceRoot":"","sources":["../../src/lightdash/loader.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,wBAAwB,EAAE,MAAM,mBAAmB,CAAC;AAWlE,OAAO,EAAE,kBAAkB,EAAE,MAAM,oCAAoC,CAAC;AAkBxE;;;;;;GAMG;AACH,wBAAsB,uBAAuB,CACzC,UAAU,EAAE,MAAM,GACnB,OAAO,CAAC,MAAM,EAAE,CAAC,CAoDnB;AAED,wBAAsB,mBAAmB,CACrC,UAAU,EAAE,MAAM,GACnB,OAAO,CAAC,wBAAwB,EAAE,CAAC,CAGrC"}
|
package/dist/lightdash/loader.js
CHANGED
|
@@ -19,9 +19,7 @@ async function isLightdashModelFile(filePath) {
|
|
|
19
19
|
if (!parsed || typeof parsed !== 'object') {
|
|
20
20
|
return false;
|
|
21
21
|
}
|
|
22
|
-
|
|
23
|
-
const validModelTypes = ['model', 'model/v1beta', 'model/v1'];
|
|
24
|
-
return validModelTypes.includes(parsed.type ?? '');
|
|
22
|
+
return (0, loader_1.isNativeModelType)(parsed.type ?? '');
|
|
25
23
|
}
|
|
26
24
|
catch {
|
|
27
25
|
return false;
|
|
@@ -36,10 +34,7 @@ async function isLightdashModelFile(filePath) {
|
|
|
36
34
|
*/
|
|
37
35
|
async function findLightdashModelFiles(projectDir) {
|
|
38
36
|
// Check both possible model locations: models/ (preferred) and lightdash/models/ (legacy)
|
|
39
|
-
const possibleDirs =
|
|
40
|
-
path.join(projectDir, 'models'),
|
|
41
|
-
path.join(projectDir, 'lightdash', 'models'),
|
|
42
|
-
];
|
|
37
|
+
const possibleDirs = loader_1.NATIVE_MODEL_DIRECTORIES.map((dir) => path.join(projectDir, dir));
|
|
43
38
|
const lightdashModelsDir = possibleDirs.find((dir) => fs.existsSync(dir));
|
|
44
39
|
if (!lightdashModelsDir) {
|
|
45
40
|
globalState_1.default.debug(`No models directory found at ${possibleDirs.join(' or ')}`);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lightdash/cli",
|
|
3
|
-
"version": "3.381.
|
|
3
|
+
"version": "3.381.3",
|
|
4
4
|
"description": "Lightdash CLI tool",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -22,8 +22,8 @@
|
|
|
22
22
|
"@actions/core": "1.11.1",
|
|
23
23
|
"@aws-sdk/credential-providers": "3.995.0",
|
|
24
24
|
"@casl/ability": "6.8.0",
|
|
25
|
-
"@lightdash/common": "3.381.
|
|
26
|
-
"@lightdash/warehouses": "3.381.
|
|
25
|
+
"@lightdash/common": "3.381.3",
|
|
26
|
+
"@lightdash/warehouses": "3.381.3",
|
|
27
27
|
"@sidvind/better-ajv-errors": "7.0.0",
|
|
28
28
|
"@types/columnify": "1.5.1",
|
|
29
29
|
"ajv": "8.18.0",
|