mirror of
https://github.com/openziti/zrok.git
synced 2025-06-19 17:27:54 +02:00
organize py module
This commit is contained in:
parent
26d1f34f4e
commit
fd2b1f12b2
3
.gitignore
vendored
3
.gitignore
vendored
@ -39,4 +39,5 @@ yarn-error.log*
|
||||
sdk/nodejs/sdk/dist
|
||||
|
||||
# py module artifacts
|
||||
*.egg-info/
|
||||
*.egg-info/
|
||||
__pycache__/
|
@ -59,14 +59,15 @@ openapi-generator-cli generate -i specs/zrok.yml -o sdk/nodejs/sdk/src/api -g ty
|
||||
echo "...generating python sdk client"
|
||||
# Delete tracked Python files
|
||||
while IFS= read -r file; do
|
||||
if [ -f "sdk/python/sdk/zrok/$file" ]; then
|
||||
echo "Removing existing file: sdk/python/sdk/zrok/$file"
|
||||
rm -f "sdk/python/sdk/zrok/$file"
|
||||
if [ -f "sdk/python/src/$file" ]; then
|
||||
echo "Removing existing file: sdk/python/src/$file"
|
||||
rm -f "sdk/python/src/$file"
|
||||
fi
|
||||
done < sdk/python/sdk/zrok/.openapi-generator/FILES
|
||||
done < sdk/python/src/.openapi-generator/FILES
|
||||
# Delete the tracking file
|
||||
rm -f sdk/python/sdk/zrok/.openapi-generator/FILES
|
||||
rm -f sdk/python/src/.openapi-generator/FILES
|
||||
# Generate and track new files
|
||||
openapi-generator-cli generate -i specs/zrok.yml -o sdk/python/sdk/zrok --package-name zrok_api --additional-properties projectName=zrok -g python
|
||||
openapi-generator-cli generate -i specs/zrok.yml -o sdk/python/src/zrok -g python \
|
||||
--package-name zrok_api --additional-properties projectName=zrok
|
||||
|
||||
git checkout rest_server_zrok/configure_zrok.go
|
||||
|
@ -1 +0,0 @@
|
||||
3.0.51
|
@ -1,8 +1,8 @@
|
||||
[metadata]
|
||||
name = openziti
|
||||
author = OpenZiti Developers
|
||||
name = zrok
|
||||
author = NetFoundry
|
||||
author_email = developers@openziti.org
|
||||
description = Ziti Python SDK
|
||||
description = zrok Python SDK
|
||||
long_description = file: README.md
|
||||
long_description_content_type = text/markdown
|
||||
url = https://github.com/openziti/zrok
|
||||
@ -13,11 +13,13 @@ project_urls =
|
||||
Discussion = https://openziti.discourse.group/
|
||||
|
||||
[options]
|
||||
package_dir = # this is a dict definition meaning there's no special mapping, and
|
||||
"" = . # continues on this line to specify finding packages in the current directory
|
||||
packages = find: # include all packages found
|
||||
# Find packages in the current directory with no special mapping
|
||||
package_dir =
|
||||
= .
|
||||
packages = find:
|
||||
|
||||
[options.packages.find]
|
||||
# exclude none
|
||||
where = .
|
||||
|
||||
[flake8]
|
@ -7,13 +7,14 @@ import re
|
||||
NAME = os.getenv('ZROK_PY_NAME', "zrok")
|
||||
VERSION = "1.0.0"
|
||||
|
||||
# Define your package overrides here - these take precedence over the generated requirements.txt
|
||||
OVERRIDES = {
|
||||
# Override specific packages with version constraints different from the generated requirements.txt
|
||||
"openziti": "openziti >= 1.0.0",
|
||||
"urllib3": "urllib3 >= 2.1.0", # urllib3 2.1.0 introduced breaking changes that are implemented by openapi-generator 7.12.0
|
||||
# urllib3 2.1.0 introduced breaking changes that are implemented by openapi-generator 7.12.0
|
||||
"urllib3": "urllib3 >= 2.1.0",
|
||||
}
|
||||
|
||||
|
||||
# Parse the generated requirements.txt
|
||||
def parse_requirements(filename):
|
||||
requirements = []
|
||||
@ -37,6 +38,7 @@ def parse_requirements(filename):
|
||||
|
||||
return requirements
|
||||
|
||||
|
||||
# Combine requirements from requirements.txt and overrides
|
||||
requirements_file = Path(__file__).parent / "requirements.txt"
|
||||
REQUIRES = parse_requirements(requirements_file) + list(OVERRIDES.values())
|
Loading…
x
Reference in New Issue
Block a user