Builder - Add sap.cloud section in generateLibraryManifest
Is your feature request related to a problem? Please describe.
I cannot use the generateLibraryManifest task to generate manifests for UI5 libraries deployed to SCP Cloud Foundry Portal, because the mandatory section sap.cloud is not supported.
Describe the solution you'd like
I believe adding 2 new optional fields to the .library file, and mapping them to the sap.cloud section would be ideal.
Describe alternatives you've considered
Generating the manifest.json in a build, copying it from dist and manually adding the sap.cloud section.
Additional context
I'm using Builder for a UI5 library deployed to SCP Cloud Foundry Portal (managed Approuter).
The applications and libraries must be deployed to a html5-apps-repo service instance with the sap.cloud.service field present in their manifest.json.
From SAP Help Portal - Expose HTML5 Applications in Portal:
To expose an HTML5 Application in SAP Cloud Platform Portal , you need to add some information to the manifest.json file.
Configuration Mandatory? Description sap.cloud.serviceMandatory Defines the business service. semanticObjectandactionMandatory Defines the navigation intent, which is composed of a semantic object and the action that is performed on this object.
Obs: Although this is not documented, I've found that UI5 libraries don't need the semanticObject and action (it wouldn't make sense anyway).
This is what this section looks like:
"sap.cloud": {
"public": true,
"service": "my.example.service"
}
This is the current generated manifest.json in file manifestCreator.js:
return {
"_version": descriptorVersion.toString(),
"sap.app": await createSapApp(),
"sap.ui": createSapUi(),
"sap.ui5": createSapUI5(),
"sap.fiori": createSapFiori(),
"sap.platform.abap": createSapPlatformABAP(),
"sap.platform.hcp": createSapPlatformHCP()
};