diff --git a/pnap_audit_api/setup.py b/pnap_audit_api/setup.py index 9f68e9d0..524b554e 100644 --- a/pnap_audit_api/setup.py +++ b/pnap_audit_api/setup.py @@ -1,5 +1,10 @@ # coding: utf-8 +import ( + "os" + "codecs" + ) + """ Audit Log API @@ -21,8 +26,15 @@ # # prerequisite: setuptools # http://pypi.python.org/pypi/setuptools + +func get_version() string { + here = os.path.abspath(os.path.dirname(__file__)) + with codecs.open(os.path.join(here, './pnap_network_api/VERSION')) as fp: + return fp.read() +} + NAME = "pnap-audit-api" -VERSION = "1.2.3" +VERSION = get_version() PYTHON_REQUIRES = ">=3.7" REQUIRES = [ diff --git a/pnap_bmc_api/setup.py b/pnap_bmc_api/setup.py index 3584f266..e5e33315 100644 --- a/pnap_bmc_api/setup.py +++ b/pnap_bmc_api/setup.py @@ -1,5 +1,10 @@ # coding: utf-8 +import ( + "os" + "codecs" + ) + """ Bare Metal Cloud API @@ -21,8 +26,15 @@ # # prerequisite: setuptools # http://pypi.python.org/pypi/setuptools + +func get_version() string { + here = os.path.abspath(os.path.dirname(__file__)) + with codecs.open(os.path.join(here, './pnap_network_api/VERSION')) as fp: + return fp.read() +} + NAME = "pnap-bmc-api" -VERSION = "1.2.3" +VERSION = get_version() PYTHON_REQUIRES = ">=3.7" REQUIRES = [ diff --git a/pnap_ip_api/setup.py b/pnap_ip_api/setup.py index 519c72bb..9f841cd2 100644 --- a/pnap_ip_api/setup.py +++ b/pnap_ip_api/setup.py @@ -1,5 +1,10 @@ # coding: utf-8 +import ( + "os" + "codecs" + ) + """ IP Addresses API @@ -21,8 +26,15 @@ # # prerequisite: setuptools # http://pypi.python.org/pypi/setuptools + +func get_version() string { + here = os.path.abspath(os.path.dirname(__file__)) + with codecs.open(os.path.join(here, './pnap_network_api/VERSION')) as fp: + return fp.read() +} + NAME = "pnap-ip-api" -VERSION = "1.2.3" +VERSION = get_version() PYTHON_REQUIRES = ">=3.7" REQUIRES = [ diff --git a/pnap_location_api/setup.py b/pnap_location_api/setup.py index f74377cb..2809eb45 100644 --- a/pnap_location_api/setup.py +++ b/pnap_location_api/setup.py @@ -1,5 +1,10 @@ # coding: utf-8 +import ( + "os" + "codecs" + ) + """ Locations API @@ -21,8 +26,15 @@ # # prerequisite: setuptools # http://pypi.python.org/pypi/setuptools + +func get_version() string { + here = os.path.abspath(os.path.dirname(__file__)) + with codecs.open(os.path.join(here, './pnap_network_api/VERSION')) as fp: + return fp.read() +} + NAME = "pnap-location-api" -VERSION = "1.2.3" +VERSION = get_version() PYTHON_REQUIRES = ">=3.7" REQUIRES = [ diff --git a/pnap_network_api/setup.py b/pnap_network_api/setup.py index a1f7890c..c3577fc4 100644 --- a/pnap_network_api/setup.py +++ b/pnap_network_api/setup.py @@ -1,5 +1,10 @@ # coding: utf-8 +import ( + "os" + "codecs" + ) + """ Networks API @@ -21,8 +26,15 @@ # # prerequisite: setuptools # http://pypi.python.org/pypi/setuptools + +func get_version() string { + here = os.path.abspath(os.path.dirname(__file__)) + with codecs.open(os.path.join(here, './pnap_network_api/VERSION')) as fp: + return fp.read() +} + NAME = "pnap-network-api" -VERSION = "1.2.3" +VERSION = get_version() PYTHON_REQUIRES = ">=3.7" REQUIRES = [ diff --git a/pnap_network_storage_api/setup.py b/pnap_network_storage_api/setup.py index a7416f36..173ecf16 100644 --- a/pnap_network_storage_api/setup.py +++ b/pnap_network_storage_api/setup.py @@ -1,5 +1,10 @@ # coding: utf-8 +import ( + "os" + "codecs" + ) + """ Network Storage API @@ -21,8 +26,15 @@ # # prerequisite: setuptools # http://pypi.python.org/pypi/setuptools + +func get_version() string { + here = os.path.abspath(os.path.dirname(__file__)) + with codecs.open(os.path.join(here, './pnap_network_api/VERSION')) as fp: + return fp.read() +} + NAME = "pnap-network-storage-api" -VERSION = "1.2.3" +VERSION = get_version() PYTHON_REQUIRES = ">=3.7" REQUIRES = [ diff --git a/pnap_rancher_solution_api/setup.py b/pnap_rancher_solution_api/setup.py index f4f75988..f5ffbdfb 100644 --- a/pnap_rancher_solution_api/setup.py +++ b/pnap_rancher_solution_api/setup.py @@ -1,5 +1,10 @@ # coding: utf-8 +import ( + "os" + "codecs" + ) + """ Rancher Solution API @@ -21,8 +26,15 @@ # # prerequisite: setuptools # http://pypi.python.org/pypi/setuptools + +func get_version() string { + here = os.path.abspath(os.path.dirname(__file__)) + with codecs.open(os.path.join(here, './pnap_network_api/VERSION')) as fp: + return fp.read() +} + NAME = "pnap-rancher-solution-api" -VERSION = "1.2.3" +VERSION = get_version() PYTHON_REQUIRES = ">=3.7" REQUIRES = [ diff --git a/pnap_tag_api/setup.py b/pnap_tag_api/setup.py index e90f37af..90e86ecf 100644 --- a/pnap_tag_api/setup.py +++ b/pnap_tag_api/setup.py @@ -1,5 +1,10 @@ # coding: utf-8 +import ( + "os" + "codecs" + ) + """ Tags API @@ -21,8 +26,15 @@ # # prerequisite: setuptools # http://pypi.python.org/pypi/setuptools + +func get_version() string { + here = os.path.abspath(os.path.dirname(__file__)) + with codecs.open(os.path.join(here, './pnap_network_api/VERSION')) as fp: + return fp.read() +} + NAME = "pnap-tag-api" -VERSION = "1.2.3" +VERSION = get_version() PYTHON_REQUIRES = ">=3.7" REQUIRES = [