cloud-sdk-js icon indicating copy to clipboard operation
cloud-sdk-js copied to clipboard

refactor: unify package generator

Open shojisoma opened this issue 3 years ago • 0 comments

Closes https://github.com/SAP/cloud-sdk-backlog/issues/604

this unifies 4 package description generators into one. the 4 generators are in these files

1 & 2. https://github.com/SAP/cloud-sdk-js/blob/main/packages/generator/src/package-description.ts 3. https://github.com/SAP/cloud-sdk-js/blob/main/packages/openapi-generator/src/sdk-metadata/package-description.ts 4. https://github.com/SAP/cloud-sdk-js/blob/8283b44208f4d767a2e135a98dc55832b34b3e51/packages/openapi-generator/src/file-serializer/package-json.ts

Changes

  • unified 4 package description generators into one below and change the sentence not to use VDM
#packages/generator-common/src/package-description.ts
const packageDescription = (packageName: string): string =>
  `SAP Cloud SDK for JavaScript: Generated client for service ${packageName
    .split('-')
    .join(' ')}`;
  • remove the 4 functions
  • made changes in function calls that call the 4 geneators in order to accept a new unified one

shojisoma avatar Aug 17 '22 11:08 shojisoma