Update code-gen to generate Angular client for Palantir API
Modified the Docker setup to generate a TypeScript-Angular client from the Palantir API. Added configuration options via a new `options.json` file and updated paths to align with the Angular frontend. Adjusted the script to replace the old client location with the updated Angular client path.
This commit is contained in:
parent
9caf5a0003
commit
ae59139fdf
1
docker/.gitignore
vendored
1
docker/.gitignore
vendored
@ -1,2 +1,3 @@
|
|||||||
code-gen/
|
code-gen/
|
||||||
!code-gen/**/docker-compose.yml
|
!code-gen/**/docker-compose.yml
|
||||||
|
!code-gen/**/config.json
|
||||||
@ -26,13 +26,13 @@ services:
|
|||||||
image: swaggerapi/swagger-codegen-cli-v3
|
image: swaggerapi/swagger-codegen-cli-v3
|
||||||
container_name: codegen-cli
|
container_name: codegen-cli
|
||||||
command: >
|
command: >
|
||||||
config-help
|
generate
|
||||||
|
-i http://palantir:5035/openapi/v1.json
|
||||||
-l typescript-angular
|
-l typescript-angular
|
||||||
# generate
|
-o /local
|
||||||
# -i http://palantir:5035/openapi/v1.json
|
-c /options.json
|
||||||
# -l csharp
|
# config-help
|
||||||
# -o /local
|
# -l typescript-angular
|
||||||
# -c /options.json
|
|
||||||
restart: no
|
restart: no
|
||||||
depends_on:
|
depends_on:
|
||||||
palantir:
|
palantir:
|
||||||
|
|||||||
9
docker/code-gen/options.json
Normal file
9
docker/code-gen/options.json
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"supportsES6": true,
|
||||||
|
"npmName": "@gandalf/api",
|
||||||
|
"npmVersion": "0.0.1",
|
||||||
|
"withInterfaces": true,
|
||||||
|
"ngVersion": "19.1.0",
|
||||||
|
"providedInRoot": true,
|
||||||
|
"useOverride": true
|
||||||
|
}
|
||||||
@ -5,6 +5,6 @@ rmdir /s /q "dotnet"
|
|||||||
xcopy "../../src/dotnet" "./dotnet\" /E/H
|
xcopy "../../src/dotnet" "./dotnet\" /E/H
|
||||||
cmd /c "docker-compose up --abort-on-container-exit --force-recreate"
|
cmd /c "docker-compose up --abort-on-container-exit --force-recreate"
|
||||||
cmd /c "docker-compose down"
|
cmd /c "docker-compose down"
|
||||||
rmdir /s /q "../../src/dotnet/Suspectus.Gandalf.Palantir.Client/Generated"
|
rmdir /s /q "../../src/angular/frontend/src/app/clients/palantir-client-bot"
|
||||||
xcopy "./palantir-client" "../../src/dotnet/Suspectus.Gandalf.Palantir.Client/Generated\" /E/H
|
xcopy "./palantir-client" "../../src/angular/frontend/src/app/clients/palantir-client-bot\" /E/H
|
||||||
popd
|
popd
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user