opticore-installer 1.2.56 → 1.2.58
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.cjs +26 -18
- package/dist/index.js +26 -18
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -619,8 +619,8 @@ var SUpdateEnv = class {
|
|
|
619
619
|
// src/presentations/middlewares/templateProject/templateProject.middleware.ts
|
|
620
620
|
var MTemplateProject = async (repoGit, projectPath, currentPath, callback, arg, projectName, argumentConnection) => {
|
|
621
621
|
await SProjectCreation(repoGit, projectPath, currentPath, projectName);
|
|
622
|
-
await callback([]);
|
|
623
622
|
new SUpdateEnv(arg, argumentConnection);
|
|
623
|
+
await callback([]);
|
|
624
624
|
};
|
|
625
625
|
|
|
626
626
|
// src/presentations/middlewares/database/createMongo.database.ts
|
|
@@ -843,45 +843,53 @@ var MSelectDB = async (projectPath, currentPath, projectName) => {
|
|
|
843
843
|
});
|
|
844
844
|
return dbChosen;
|
|
845
845
|
} else {
|
|
846
|
+
const envParams = params.envParams;
|
|
846
847
|
dbSelect.map(async (item) => {
|
|
847
848
|
switch (item) {
|
|
848
|
-
case CDbNameValue.mysql:
|
|
849
|
+
case CDbNameValue.mysql: {
|
|
850
|
+
const mysqlParams = { ...envParams, projectPath };
|
|
849
851
|
await MTemplateProject(
|
|
850
852
|
CProjectTemplatePath.mysql,
|
|
851
853
|
projectPath,
|
|
852
854
|
currentPath,
|
|
853
|
-
async () => await createMySQLDatabase(
|
|
854
|
-
|
|
855
|
-
params.dbParams
|
|
856
|
-
),
|
|
857
|
-
params.envParams,
|
|
855
|
+
async () => await createMySQLDatabase(mysqlParams),
|
|
856
|
+
envParams,
|
|
858
857
|
projectName,
|
|
859
858
|
CConnectionProperties
|
|
860
859
|
);
|
|
861
860
|
break;
|
|
862
|
-
|
|
861
|
+
}
|
|
862
|
+
case CDbNameValue.postgresql: {
|
|
863
|
+
const postgresParams = {
|
|
864
|
+
host: envParams.dbHost,
|
|
865
|
+
user: envParams.dbUser,
|
|
866
|
+
password: envParams.dbPwd,
|
|
867
|
+
port: envParams.dbPort,
|
|
868
|
+
database: envParams.dbName,
|
|
869
|
+
projectName
|
|
870
|
+
};
|
|
863
871
|
await MTemplateProject(
|
|
864
872
|
CProjectTemplatePath.postgresql,
|
|
865
873
|
projectPath,
|
|
866
874
|
currentPath,
|
|
867
|
-
async () => await createPostgresDatabase(
|
|
868
|
-
|
|
869
|
-
params.dbParams
|
|
870
|
-
),
|
|
871
|
-
params.envParams,
|
|
875
|
+
async () => await createPostgresDatabase(postgresParams),
|
|
876
|
+
envParams,
|
|
872
877
|
projectName
|
|
873
878
|
);
|
|
874
879
|
break;
|
|
875
|
-
|
|
880
|
+
}
|
|
881
|
+
case CDbNameValue.mongodb: {
|
|
882
|
+
const mongoParams = { ...envParams, projectPath };
|
|
876
883
|
await MTemplateProject(
|
|
877
884
|
CProjectTemplatePath.mongodb,
|
|
878
885
|
projectPath,
|
|
879
886
|
currentPath,
|
|
880
|
-
async () => await createMongoDatabase(
|
|
881
|
-
|
|
887
|
+
async () => await createMongoDatabase(mongoParams),
|
|
888
|
+
envParams,
|
|
882
889
|
projectName
|
|
883
890
|
);
|
|
884
891
|
break;
|
|
892
|
+
}
|
|
885
893
|
case CDbNameValue.oracle:
|
|
886
894
|
await MTemplateProject(
|
|
887
895
|
CProjectTemplatePath.oracle,
|
|
@@ -889,7 +897,7 @@ var MSelectDB = async (projectPath, currentPath, projectName) => {
|
|
|
889
897
|
currentPath,
|
|
890
898
|
async () => {
|
|
891
899
|
},
|
|
892
|
-
|
|
900
|
+
envParams,
|
|
893
901
|
projectName
|
|
894
902
|
);
|
|
895
903
|
break;
|
|
@@ -900,7 +908,7 @@ var MSelectDB = async (projectPath, currentPath, projectName) => {
|
|
|
900
908
|
currentPath,
|
|
901
909
|
async () => {
|
|
902
910
|
},
|
|
903
|
-
|
|
911
|
+
envParams,
|
|
904
912
|
projectName
|
|
905
913
|
);
|
|
906
914
|
break;
|
package/dist/index.js
CHANGED
|
@@ -596,8 +596,8 @@ var SUpdateEnv = class {
|
|
|
596
596
|
// src/presentations/middlewares/templateProject/templateProject.middleware.ts
|
|
597
597
|
var MTemplateProject = async (repoGit, projectPath, currentPath, callback, arg, projectName, argumentConnection) => {
|
|
598
598
|
await SProjectCreation(repoGit, projectPath, currentPath, projectName);
|
|
599
|
-
await callback([]);
|
|
600
599
|
new SUpdateEnv(arg, argumentConnection);
|
|
600
|
+
await callback([]);
|
|
601
601
|
};
|
|
602
602
|
|
|
603
603
|
// src/presentations/middlewares/database/createMongo.database.ts
|
|
@@ -820,45 +820,53 @@ var MSelectDB = async (projectPath, currentPath, projectName) => {
|
|
|
820
820
|
});
|
|
821
821
|
return dbChosen;
|
|
822
822
|
} else {
|
|
823
|
+
const envParams = params.envParams;
|
|
823
824
|
dbSelect.map(async (item) => {
|
|
824
825
|
switch (item) {
|
|
825
|
-
case CDbNameValue.mysql:
|
|
826
|
+
case CDbNameValue.mysql: {
|
|
827
|
+
const mysqlParams = { ...envParams, projectPath };
|
|
826
828
|
await MTemplateProject(
|
|
827
829
|
CProjectTemplatePath.mysql,
|
|
828
830
|
projectPath,
|
|
829
831
|
currentPath,
|
|
830
|
-
async () => await createMySQLDatabase(
|
|
831
|
-
|
|
832
|
-
params.dbParams
|
|
833
|
-
),
|
|
834
|
-
params.envParams,
|
|
832
|
+
async () => await createMySQLDatabase(mysqlParams),
|
|
833
|
+
envParams,
|
|
835
834
|
projectName,
|
|
836
835
|
CConnectionProperties
|
|
837
836
|
);
|
|
838
837
|
break;
|
|
839
|
-
|
|
838
|
+
}
|
|
839
|
+
case CDbNameValue.postgresql: {
|
|
840
|
+
const postgresParams = {
|
|
841
|
+
host: envParams.dbHost,
|
|
842
|
+
user: envParams.dbUser,
|
|
843
|
+
password: envParams.dbPwd,
|
|
844
|
+
port: envParams.dbPort,
|
|
845
|
+
database: envParams.dbName,
|
|
846
|
+
projectName
|
|
847
|
+
};
|
|
840
848
|
await MTemplateProject(
|
|
841
849
|
CProjectTemplatePath.postgresql,
|
|
842
850
|
projectPath,
|
|
843
851
|
currentPath,
|
|
844
|
-
async () => await createPostgresDatabase(
|
|
845
|
-
|
|
846
|
-
params.dbParams
|
|
847
|
-
),
|
|
848
|
-
params.envParams,
|
|
852
|
+
async () => await createPostgresDatabase(postgresParams),
|
|
853
|
+
envParams,
|
|
849
854
|
projectName
|
|
850
855
|
);
|
|
851
856
|
break;
|
|
852
|
-
|
|
857
|
+
}
|
|
858
|
+
case CDbNameValue.mongodb: {
|
|
859
|
+
const mongoParams = { ...envParams, projectPath };
|
|
853
860
|
await MTemplateProject(
|
|
854
861
|
CProjectTemplatePath.mongodb,
|
|
855
862
|
projectPath,
|
|
856
863
|
currentPath,
|
|
857
|
-
async () => await createMongoDatabase(
|
|
858
|
-
|
|
864
|
+
async () => await createMongoDatabase(mongoParams),
|
|
865
|
+
envParams,
|
|
859
866
|
projectName
|
|
860
867
|
);
|
|
861
868
|
break;
|
|
869
|
+
}
|
|
862
870
|
case CDbNameValue.oracle:
|
|
863
871
|
await MTemplateProject(
|
|
864
872
|
CProjectTemplatePath.oracle,
|
|
@@ -866,7 +874,7 @@ var MSelectDB = async (projectPath, currentPath, projectName) => {
|
|
|
866
874
|
currentPath,
|
|
867
875
|
async () => {
|
|
868
876
|
},
|
|
869
|
-
|
|
877
|
+
envParams,
|
|
870
878
|
projectName
|
|
871
879
|
);
|
|
872
880
|
break;
|
|
@@ -877,7 +885,7 @@ var MSelectDB = async (projectPath, currentPath, projectName) => {
|
|
|
877
885
|
currentPath,
|
|
878
886
|
async () => {
|
|
879
887
|
},
|
|
880
|
-
|
|
888
|
+
envParams,
|
|
881
889
|
projectName
|
|
882
890
|
);
|
|
883
891
|
break;
|