From 4d85c4c6affdc336ce420aa741cd863febfc6b8d Mon Sep 17 00:00:00 2001 From: avollkopf <43980694+avollkopf@users.noreply.github.com> Date: Sat, 16 Jul 2022 10:26:32 +0200 Subject: [PATCH] Update minor version --- .devcontainer/cbpi-dev-config/config.json | 16 ++++++++++++++++ .gitignore | 1 + cbpi/__init__.py | 2 +- testversion.py | 13 +++++++++++++ 4 files changed, 31 insertions(+), 1 deletion(-) create mode 100644 testversion.py diff --git a/.devcontainer/cbpi-dev-config/config.json b/.devcontainer/cbpi-dev-config/config.json index f6899f3..a94c57a 100644 --- a/.devcontainer/cbpi-dev-config/config.json +++ b/.devcontainer/cbpi-dev-config/config.json @@ -177,6 +177,22 @@ "type": "select", "value": 0 }, + "PRESSURE_UNIT": { + "description": "Set unit for pressure", + "name": "PRESSURE_UNIT", + "options": [ + { + "label": "kPa", + "value": "kPa" + }, + { + "label": "PSI", + "value": "PSI" + } + ], + "type": "select", + "value": "kPa" + }, "RECIPE_CREATION_PATH": { "description": "API path to creation plugin. Default: upload . CHANGE ONLY IF USING A RECIPE CREATION PLUGIN", "name": "RECIPE_CREATION_PATH", diff --git a/.gitignore b/.gitignore index 6349f01..bb723ac 100644 --- a/.gitignore +++ b/.gitignore @@ -5,6 +5,7 @@ dist .idea *.log cbpi.egg-info +cbpi4.egg-info log venv cbpi/extension/ui diff --git a/cbpi/__init__.py b/cbpi/__init__.py index 2e6c461..d8703f2 100644 --- a/cbpi/__init__.py +++ b/cbpi/__init__.py @@ -1,3 +1,3 @@ -__version__ = "4.0.6" +__version__ = "4.0.7.a1" __codename__ = "Spring Break" diff --git a/testversion.py b/testversion.py new file mode 100644 index 0000000..0baaf67 --- /dev/null +++ b/testversion.py @@ -0,0 +1,13 @@ +import json +import sys +from urllib import request +from pkg_resources import parse_version + +def versions(pkg_name): + url = f'https://pypi.python.org/pypi/{pkg_name}/json' + releases = json.loads(request.urlopen(url).read())['releases'] + releases = sorted(releases, key=parse_version, reverse=True) + return [releases[0]] + +if __name__ == '__main__': + print(*versions(sys.argv[1]), sep='\n') \ No newline at end of file