Commit 15f42893 authored by u15767's avatar u15767
Browse files

corrected the build process and referenced the right OpenAPI file

parent 3cf18be6
Loading
Loading
Loading
Loading
+20 −4
Original line number Diff line number Diff line
# Description

This is a small project generating the C# client code and dll for the ISG ARF World Storage.
This is a small project generating the C# client code and DLLs for the ISG ARF World Storage.

# How to checkout

This project contains a submodule. This submodule contains the OpenAPI specification of the ISG ARF World Storage. To correctly compile the project you also need to checkout the submodule. See git submodules (https://git-scm.com/book/en/v2/Git-Tools-Submodules) for more information.

The simplest way to check out the project including the submodule is to use the following command:

    git clone --recurse-submodules https://labs.etsi.org/rep/arf/world-storage-api-helpers/world-storage-csharp-client.git

# How to update the API specification

The referenced submodule contains the OpenAPI specification of the ISG ARF World Storage. To checkout the newest version of it use the following commands:

    cd ARF005WorldStorageAPI
    git checkout master
    cd ..

# Code Generation

To generate the code use the following commands:
To generate the code and the DLLs use the following commands:

    npm install
    npm run generate
    npm run build

The library is then contained in the folder `generated_client/src/Org.OpenAPITools/bin/Debug/netstandard2.0/Org.OpenAPITools.dll`.
The generated library and its depencies are then contained in the folder `generated_client/bin`.
+18 −1
Original line number Diff line number Diff line
@@ -12,7 +12,8 @@
      },
      "devDependencies": {
        "@openapitools/openapi-generator-cli": "^2.4.23",
        "dotnet-sdk-3.1": "^3.1.1007"
        "dotnet-sdk-3.1": "^3.1.1007",
        "run-script-os": "^1.1.6"
      }
    },
    "node_modules/@nestjs/common": {
@@ -983,6 +984,16 @@
        "node": ">=0.12.0"
      }
    },
    "node_modules/run-script-os": {
      "version": "1.1.6",
      "resolved": "https://registry.npmjs.org/run-script-os/-/run-script-os-1.1.6.tgz",
      "integrity": "sha512-ql6P2LzhBTTDfzKts+Qo4H94VUKpxKDFz6QxxwaUZN0mwvi7L3lpOI7BqPCq7lgDh3XLl0dpeXwfcVIitlrYrw==",
      "dev": true,
      "bin": {
        "run-os": "index.js",
        "run-script-os": "index.js"
      }
    },
    "node_modules/rxjs": {
      "version": "7.5.1",
      "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-7.5.1.tgz",
@@ -1906,6 +1917,12 @@
      "integrity": "sha512-tvVnVv01b8c1RrA6Ep7JkStj85Guv/YrMcwqYQnwjsAS2cTmmPGBBjAjpCW7RrSodNSoE2/qg9O4bceNvUuDgQ==",
      "dev": true
    },
    "run-script-os": {
      "version": "1.1.6",
      "resolved": "https://registry.npmjs.org/run-script-os/-/run-script-os-1.1.6.tgz",
      "integrity": "sha512-ql6P2LzhBTTDfzKts+Qo4H94VUKpxKDFz6QxxwaUZN0mwvi7L3lpOI7BqPCq7lgDh3XLl0dpeXwfcVIitlrYrw==",
      "dev": true
    },
    "rxjs": {
      "version": "7.5.1",
      "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-7.5.1.tgz",
+5 −3
Original line number Diff line number Diff line
@@ -4,12 +4,14 @@
  "description": "ISG ARF World Storage C# Client",
  "scripts": {
    "clean": "rm -rf generated_client",
    "generate": "npx @openapitools/openapi-generator-cli generate -i ../ISG-ARF-005-API/API/OpenAPI.yml -g csharp -o generated_client",
    "build": "dotnet build generated_client"
    "build": "npx @openapitools/openapi-generator-cli generate -i ../ISG-ARF-005-API/API/OpenAPI.yml -g csharp -o generated_client && run-script-os",
    "build:win32": "cd generated_client && build.bat",
    "build:default": "cd generated_client && build.sh"
  },
  "devDependencies": {
    "@openapitools/openapi-generator-cli": "^2.4.23",
    "dotnet-sdk-3.1": "^3.1.1007"
    "dotnet-sdk-3.1": "^3.1.1007",
    "run-script-os": "^1.1.6"
  },
  "dependencies": {
    "dotnet-3.1": "*"