@lightdash/cli 0.2183.0 → 0.2184.0
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":"getDbtVersion.d.ts","sourceRoot":"","sources":["../../../src/handlers/dbt/getDbtVersion.ts"],"names":[],"mappings":"AAAA,OAAO,EACH,gBAAgB,EAMnB,MAAM,mBAAmB,CAAC;AAO3B,eAAO,MAAM,mBAAmB,QAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"getDbtVersion.d.ts","sourceRoot":"","sources":["../../../src/handlers/dbt/getDbtVersion.ts"],"names":[],"mappings":"AAAA,OAAO,EACH,gBAAgB,EAMnB,MAAM,mBAAmB,CAAC;AAO3B,eAAO,MAAM,mBAAmB,QAAoB,CAAC;AAyDrD,KAAK,UAAU,GAAG;IACd,cAAc,EAAE,MAAM,CAAC;IACvB,aAAa,EAAE,gBAAgB,CAAC;IAChC,aAAa,EAAE,OAAO,CAAC;CAC1B,CAAC;AAEF,eAAO,MAAM,aAAa,QAAa,OAAO,CAAC,UAAU,CA8ExD,CAAC"}
|
|
@@ -9,6 +9,7 @@ const globalState_1 = tslib_1.__importDefault(require("../../globalState"));
|
|
|
9
9
|
const styles = tslib_1.__importStar(require("../../styles"));
|
|
10
10
|
const DBT_CORE_VERSION_REGEX = /installed:.*/;
|
|
11
11
|
exports.DBT_CLOUD_CLI_REGEX = /dbt Cloud CLI.*/;
|
|
12
|
+
const DBT_FUSION_VERSION_REGEX = /dbt-fusion.*/;
|
|
12
13
|
const getDbtCLIVersion = async () => {
|
|
13
14
|
try {
|
|
14
15
|
const { all } = await (0, execa_1.default)('dbt', ['--version'], {
|
|
@@ -20,6 +21,10 @@ const getDbtCLIVersion = async () => {
|
|
|
20
21
|
if (cloudVersion) {
|
|
21
22
|
return cloudVersion[0];
|
|
22
23
|
}
|
|
24
|
+
const fusionVersion = logs.match(DBT_FUSION_VERSION_REGEX);
|
|
25
|
+
if (fusionVersion) {
|
|
26
|
+
return fusionVersion[0]; // eg: dbt-fusion 2.0.0-preview.65
|
|
27
|
+
}
|
|
23
28
|
const version = logs.match(DBT_CORE_VERSION_REGEX);
|
|
24
29
|
if (version === null || version.length === 0)
|
|
25
30
|
throw new common_1.ParseError(`Can't locate dbt --version: ${logs}`);
|
|
@@ -34,6 +39,8 @@ const isDbtCloudCLI = (version) => version.match(exports.DBT_CLOUD_CLI_REGEX) !=
|
|
|
34
39
|
const getSupportedDbtVersionOption = (version) => {
|
|
35
40
|
if (version.match(exports.DBT_CLOUD_CLI_REGEX))
|
|
36
41
|
return common_1.DbtVersionOptionLatest.LATEST;
|
|
42
|
+
if (version.match(DBT_FUSION_VERSION_REGEX))
|
|
43
|
+
return common_1.DbtVersionOptionLatest.LATEST;
|
|
37
44
|
if (version.startsWith('1.4.'))
|
|
38
45
|
return common_1.SupportedDbtVersions.V1_4;
|
|
39
46
|
if (version.startsWith('1.5.'))
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lightdash/cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.2184.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"bin": {
|
|
6
6
|
"lightdash": "dist/index.js"
|
|
@@ -33,8 +33,8 @@
|
|
|
33
33
|
"parse-node-version": "^2.0.0",
|
|
34
34
|
"unique-names-generator": "^4.7.1",
|
|
35
35
|
"uuid": "^11.0.3",
|
|
36
|
-
"@lightdash/common": "0.
|
|
37
|
-
"@lightdash/warehouses": "0.
|
|
36
|
+
"@lightdash/common": "0.2184.0",
|
|
37
|
+
"@lightdash/warehouses": "0.2184.0"
|
|
38
38
|
},
|
|
39
39
|
"description": "Lightdash CLI tool",
|
|
40
40
|
"devDependencies": {
|