diff --git a/bin/configs/python-pydantic-v1.yaml b/bin/configs/python-pydantic-v1.yaml index af6786e6633..10656567265 100644 --- a/bin/configs/python-pydantic-v1.yaml +++ b/bin/configs/python-pydantic-v1.yaml @@ -2,6 +2,9 @@ generatorName: python-pydantic-v1 outputDir: samples/openapi3/client/petstore/python-pydantic-v1 inputSpec: modules/openapi-generator/src/test/resources/3_0/python/petstore-with-fake-endpoints-models-for-testing.yaml templateDir: modules/openapi-generator/src/main/resources/python-pydantic-v1 +gitHost: GIT_HOST +gitUserId: GIT_USER_ID +gitRepoId: GIT_REPO_ID additionalProperties: packageName: petstore_api useOneOfDiscriminatorLookup: "true" diff --git a/modules/openapi-generator/src/main/resources/python-pydantic-v1/pyproject.mustache b/modules/openapi-generator/src/main/resources/python-pydantic-v1/pyproject.mustache index 75900ed9f8a..42b2ea6d356 100644 --- a/modules/openapi-generator/src/main/resources/python-pydantic-v1/pyproject.mustache +++ b/modules/openapi-generator/src/main/resources/python-pydantic-v1/pyproject.mustache @@ -5,7 +5,7 @@ description = "{{{appName}}}" authors = ["{{infoName}}{{^infoName}}OpenAPI Generator Community{{/infoName}} <{{infoEmail}}{{^infoEmail}}team@openapitools.org{{/infoEmail}}>"] license = "{{{licenseInfo}}}{{^licenseInfo}}NoLicense{{/licenseInfo}}" readme = "README.md" -repository = "https://github.com/{{{gitUserId}}}/{{{gitRepoId}}}" +repository = "https://{{{gitHost}}}/{{{gitUserId}}}/{{{gitRepoId}}}" keywords = ["OpenAPI", "OpenAPI-Generator", "{{{appName}}}"] include = ["{{packageName}}/py.typed"] diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/README.md b/samples/openapi3/client/petstore/python-pydantic-v1/README.md index ca72751a4ae..684881a19a9 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1/README.md +++ b/samples/openapi3/client/petstore/python-pydantic-v1/README.md @@ -18,9 +18,9 @@ Python 3.7+ If the python package is hosted on a repository, you can install directly using: ```sh -pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git +pip install git+https://GIT_HOST/GIT_USER_ID/GIT_REPO_ID.git ``` -(you may need to run `pip` with root permission: `sudo pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git`) +(you may need to run `pip` with root permission: `sudo pip install git+https://GIT_HOST/GIT_USER_ID/GIT_REPO_ID.git`) Then import the package: ```python diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/git_push.sh b/samples/openapi3/client/petstore/python-pydantic-v1/git_push.sh index f53a75d4fab..bf9924d0cc1 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1/git_push.sh +++ b/samples/openapi3/client/petstore/python-pydantic-v1/git_push.sh @@ -9,7 +9,7 @@ release_note=$3 git_host=$4 if [ "$git_host" = "" ]; then - git_host="github.com" + git_host="GIT_HOST" echo "[INFO] No command line input provided. Set \$git_host to $git_host" fi diff --git a/samples/openapi3/client/petstore/python-pydantic-v1/pyproject.toml b/samples/openapi3/client/petstore/python-pydantic-v1/pyproject.toml index be791aff52a..e3a79309934 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1/pyproject.toml +++ b/samples/openapi3/client/petstore/python-pydantic-v1/pyproject.toml @@ -5,7 +5,7 @@ description = "OpenAPI Petstore" authors = ["OpenAPI Generator Community "] license = "Apache-2.0" readme = "README.md" -repository = "https://github.com/GIT_USER_ID/GIT_REPO_ID" +repository = "https://GIT_HOST/GIT_USER_ID/GIT_REPO_ID" keywords = ["OpenAPI", "OpenAPI-Generator", "OpenAPI Petstore"] include = ["petstore_api/py.typed"]