@sap-ux/create 0.12.1 → 0.12.4
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/cli/add/annotations-to-odata.js +1 -1
- package/dist/cli/add/component-usages.js +1 -1
- package/dist/cli/add/navigation-config.js +2 -2
- package/dist/cli/add/new-model.js +1 -1
- package/dist/cli/change/change-data-source.js +1 -1
- package/dist/cli/change/change-inbound.js +2 -2
- package/dist/validation/validation.d.ts +1 -1
- package/dist/validation/validation.js +2 -2
- package/package.json +12 -12
|
@@ -35,7 +35,7 @@ async function addAnnotationsToOdata(basePath, simulate, yamlPath) {
|
|
|
35
35
|
basePath = process.cwd();
|
|
36
36
|
}
|
|
37
37
|
await (0, validation_1.validateAdpProject)(basePath);
|
|
38
|
-
const variant = (0, adp_tooling_1.getVariant)(basePath);
|
|
38
|
+
const variant = await (0, adp_tooling_1.getVariant)(basePath);
|
|
39
39
|
const { target, ignoreCertErrors = false } = await (0, adp_tooling_1.getAdpConfig)(basePath, yamlPath);
|
|
40
40
|
const provider = await (0, system_access_1.createAbapServiceProvider)(target, {
|
|
41
41
|
ignoreCertErrors
|
|
@@ -31,7 +31,7 @@ async function addComponentUsages(basePath, simulate) {
|
|
|
31
31
|
basePath = process.cwd();
|
|
32
32
|
}
|
|
33
33
|
await (0, validation_1.validateAdpProject)(basePath);
|
|
34
|
-
const variant = (0, adp_tooling_1.getVariant)(basePath);
|
|
34
|
+
const variant = await (0, adp_tooling_1.getVariant)(basePath);
|
|
35
35
|
const answers = await (0, common_1.promptYUIQuestions)((0, adp_tooling_1.getPromptsForAddComponentUsages)(basePath, variant.layer), false);
|
|
36
36
|
const fs = await (0, adp_tooling_1.generateChange)(basePath, "appdescr_ui5_addComponentUsages" /* ChangeType.ADD_COMPONENT_USAGES */, createComponentUsageData(variant, answers));
|
|
37
37
|
if (!simulate) {
|
|
@@ -44,7 +44,7 @@ async function addInboundNavigationConfig(basePath, simulate) {
|
|
|
44
44
|
await (0, validation_1.validateBasePath)(basePath);
|
|
45
45
|
const appType = await (0, project_access_1.getAppType)(basePath);
|
|
46
46
|
const isAdp = appType === 'Fiori Adaptation';
|
|
47
|
-
if (isAdp && (0, adp_tooling_1.flpConfigurationExists)(basePath)) {
|
|
47
|
+
if (isAdp && (await (0, adp_tooling_1.flpConfigurationExists)(basePath))) {
|
|
48
48
|
logger.info('FLP Configuration already exists.');
|
|
49
49
|
return;
|
|
50
50
|
}
|
|
@@ -111,7 +111,7 @@ async function retrieveManifest(basePath, fs) {
|
|
|
111
111
|
* @throws {Error} If the project is not CloudReady.
|
|
112
112
|
*/
|
|
113
113
|
async function retrieveMergedManifest(basePath, logger) {
|
|
114
|
-
const variant = (0, adp_tooling_1.getVariant)(basePath);
|
|
114
|
+
const variant = await (0, adp_tooling_1.getVariant)(basePath);
|
|
115
115
|
const { target, ignoreCertErrors = false } = await (0, adp_tooling_1.getAdpConfig)(basePath, (0, path_1.join)(basePath, project_access_1.FileName.Ui5Yaml));
|
|
116
116
|
const provider = await (0, system_access_1.createAbapServiceProvider)(target, { ignoreCertErrors }, true, logger);
|
|
117
117
|
const manifestService = await adp_tooling_1.ManifestService.initMergedManifest(provider, basePath, variant, logger);
|
|
@@ -30,7 +30,7 @@ async function addNewModel(basePath, simulate) {
|
|
|
30
30
|
basePath = process.cwd();
|
|
31
31
|
}
|
|
32
32
|
await (0, validation_1.validateAdpProject)(basePath);
|
|
33
|
-
const variant = (0, adp_tooling_1.getVariant)(basePath);
|
|
33
|
+
const variant = await (0, adp_tooling_1.getVariant)(basePath);
|
|
34
34
|
const answers = await (0, common_1.promptYUIQuestions)((0, adp_tooling_1.getPromptsForNewModel)(basePath, variant.layer), false);
|
|
35
35
|
const fs = await (0, adp_tooling_1.generateChange)(basePath, "appdescr_ui5_addNewModel" /* ChangeType.ADD_NEW_MODEL */, createNewModelData(variant, answers));
|
|
36
36
|
if (!simulate) {
|
|
@@ -34,7 +34,7 @@ async function changeDataSource(basePath, simulate, yamlPath) {
|
|
|
34
34
|
basePath = process.cwd();
|
|
35
35
|
}
|
|
36
36
|
await (0, validation_1.validateAdpProject)(basePath);
|
|
37
|
-
const variant = (0, adp_tooling_1.getVariant)(basePath);
|
|
37
|
+
const variant = await (0, adp_tooling_1.getVariant)(basePath);
|
|
38
38
|
const { target, ignoreCertErrors = false } = await (0, adp_tooling_1.getAdpConfig)(basePath, yamlPath);
|
|
39
39
|
const provider = await (0, system_access_1.createAbapServiceProvider)(target, {
|
|
40
40
|
ignoreCertErrors
|
|
@@ -30,8 +30,8 @@ async function changeInbound(basePath, simulate) {
|
|
|
30
30
|
basePath = process.cwd();
|
|
31
31
|
}
|
|
32
32
|
await (0, validation_1.validateAdpProject)(basePath);
|
|
33
|
-
(0, validation_1.validateCloudAdpProject)(basePath);
|
|
34
|
-
const variant = (0, adp_tooling_1.getVariant)(basePath);
|
|
33
|
+
await (0, validation_1.validateCloudAdpProject)(basePath);
|
|
34
|
+
const variant = await (0, adp_tooling_1.getVariant)(basePath);
|
|
35
35
|
const change = variant.content.find((change) => change.changeType === 'appdescr_app_removeAllInboundsExceptOne');
|
|
36
36
|
const inboundId = change?.content?.inboundId;
|
|
37
37
|
const answers = await (0, common_1.promptYUIQuestions)((0, adp_tooling_1.getPromptsForChangeInbound)(), false);
|
|
@@ -24,5 +24,5 @@ export declare function validateAdpProject(basePath: string): Promise<void>;
|
|
|
24
24
|
*
|
|
25
25
|
* @param basePath - path to the adaptation project
|
|
26
26
|
*/
|
|
27
|
-
export declare function validateCloudAdpProject(basePath: string): void
|
|
27
|
+
export declare function validateCloudAdpProject(basePath: string): Promise<void>;
|
|
28
28
|
//# sourceMappingURL=validation.d.ts.map
|
|
@@ -53,8 +53,8 @@ async function validateAdpProject(basePath) {
|
|
|
53
53
|
*
|
|
54
54
|
* @param basePath - path to the adaptation project
|
|
55
55
|
*/
|
|
56
|
-
function validateCloudAdpProject(basePath) {
|
|
57
|
-
const manifest = (0, adp_tooling_1.getVariant)(basePath);
|
|
56
|
+
async function validateCloudAdpProject(basePath) {
|
|
57
|
+
const manifest = await (0, adp_tooling_1.getVariant)(basePath);
|
|
58
58
|
if (!manifest?.content?.some((change) => change.changeType === 'appdescr_app_removeAllInboundsExceptOne')) {
|
|
59
59
|
throw new Error('This command can only be used for Cloud Adaptation Project.');
|
|
60
60
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sap-ux/create",
|
|
3
3
|
"description": "SAP Fiori tools module to add or remove features",
|
|
4
|
-
"version": "0.12.
|
|
4
|
+
"version": "0.12.4",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "https://github.com/SAP/open-ux-tools.git",
|
|
@@ -30,20 +30,20 @@
|
|
|
30
30
|
"mem-fs": "2.1.0",
|
|
31
31
|
"mem-fs-editor": "9.4.0",
|
|
32
32
|
"prompts": "2.4.2",
|
|
33
|
-
"@sap-ux/abap-deploy-config-inquirer": "1.2.
|
|
34
|
-
"@sap-ux/abap-deploy-config-writer": "0.0.
|
|
35
|
-
"@sap-ux/adp-tooling": "0.13.
|
|
36
|
-
"@sap-ux/app-config-writer": "0.5.
|
|
37
|
-
"@sap-ux/cap-config-writer": "0.9.
|
|
33
|
+
"@sap-ux/abap-deploy-config-inquirer": "1.2.21",
|
|
34
|
+
"@sap-ux/abap-deploy-config-writer": "0.0.91",
|
|
35
|
+
"@sap-ux/adp-tooling": "0.13.4",
|
|
36
|
+
"@sap-ux/app-config-writer": "0.5.34",
|
|
37
|
+
"@sap-ux/cap-config-writer": "0.9.13",
|
|
38
38
|
"@sap-ux/cards-editor-config-writer": "0.4.10",
|
|
39
39
|
"@sap-ux/logger": "0.6.0",
|
|
40
|
-
"@sap-ux/mockserver-config-writer": "0.8.
|
|
41
|
-
"@sap-ux/odata-service-writer": "0.26.
|
|
42
|
-
"@sap-ux/preview-middleware": "0.18.
|
|
43
|
-
"@sap-ux/project-access": "1.29.
|
|
40
|
+
"@sap-ux/mockserver-config-writer": "0.8.3",
|
|
41
|
+
"@sap-ux/odata-service-writer": "0.26.5",
|
|
42
|
+
"@sap-ux/preview-middleware": "0.18.4",
|
|
43
|
+
"@sap-ux/project-access": "1.29.10",
|
|
44
44
|
"@sap-ux/system-access": "0.5.31",
|
|
45
45
|
"@sap-ux/ui5-config": "0.26.2",
|
|
46
|
-
"@sap-ux/flp-config-inquirer": "0.2.
|
|
46
|
+
"@sap-ux/flp-config-inquirer": "0.2.49"
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|
|
49
49
|
"@types/diff": "5.0.9",
|
|
@@ -51,7 +51,7 @@
|
|
|
51
51
|
"@types/mem-fs": "1.1.2",
|
|
52
52
|
"@types/mem-fs-editor": "7.0.1",
|
|
53
53
|
"@types/prompts": "2.4.4",
|
|
54
|
-
"@sap-ux/inquirer-common": "0.6.
|
|
54
|
+
"@sap-ux/inquirer-common": "0.6.22",
|
|
55
55
|
"@sap-ux/store": "1.0.0"
|
|
56
56
|
},
|
|
57
57
|
"scripts": {
|