Skip to content

Commit d5dd07c

Browse files
committed
get version through poetry
1 parent 82ecba2 commit d5dd07c

File tree

3 files changed

+9
-3
lines changed

3 files changed

+9
-3
lines changed

app_mac_m1.spec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# -*- mode: python ; coding: utf-8 -*-
22
from PyInstaller.utils.hooks import collect_data_files
33

4-
datas = []
4+
datas = [('pyproject.toml', '.')]
55
datas += collect_data_files('ciscoreset')
66
datas += collect_data_files('ciscoaxl')
77

app_windows_x64.spec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# -*- mode: python ; coding: utf-8 -*-
22
from PyInstaller.utils.hooks import collect_data_files
33

4-
datas = []
4+
datas = [('pyproject.toml', '.')]
55
datas += collect_data_files('ciscoreset')
66
datas += collect_data_files('ciscoaxl')
77

ciscoreset/__init__.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,13 @@
1-
__version__ = "0.1.0"
1+
import toml
2+
23
from .axl import CUCM
34
from .credentials import get_credentials
45
from .keys import KEY_SUPPORT
56
from .vision import get_menu_position, get_list_position
67
from .xml import XMLPhone
78
from .phone import PhoneConnection
9+
from .configs import ROOT_DIR
10+
11+
__version__ = toml.load(str(ROOT_DIR.parent / "pyproject.toml"))["tool"]["poetry"][
12+
"version"
13+
]

0 commit comments

Comments
 (0)