Skip to content

Commit 91c1f4a

Browse files
committed
Added support for pipx
1 parent 90101b3 commit 91c1f4a

File tree

4 files changed

+20
-5
lines changed

4 files changed

+20
-5
lines changed

gui.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,6 @@
55
MAIN FILE
66
"""
77

8-
from pydetex.gui import PyDetexGUI
8+
from pydetex.gui import main
99

10-
PyDetexGUI().start()
10+
main()

pydetex/gui.py

+9-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
Basic gui that convers and executes a given pipeline.
77
"""
88

9-
__all__ = ['PyDetexGUI']
9+
__all__ = ['PyDetexGUI', 'main']
1010

1111
import concurrent.futures
1212
import tkinter as tk
@@ -815,5 +815,12 @@ def _check_version_event(self) -> None:
815815
)
816816

817817

818-
if __name__ == '__main__':
818+
def main() -> None:
819+
"""
820+
Main app entry.
821+
"""
819822
PyDetexGUI().start()
823+
824+
825+
if __name__ == '__main__':
826+
main()

pydetex/version.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,6 @@ def __str__(self) -> str:
3232
patch = property(lambda self: self[2])
3333

3434

35-
vernum = Version(1, 0, 7)
35+
vernum = Version(1, 0, 8)
3636
ver = str(vernum)
3737
rev = ''

setup.py

+8
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,14 @@
5252
packages=find_packages(exclude=['test']),
5353
python_requires='>=3.7, <4',
5454
install_requires=requirements,
55+
entry_points={
56+
'console_scripts': [
57+
'pydetex = pydetex.gui:main',
58+
],
59+
'gui_scripts': [
60+
'pydetex = pydetex.gui:main',
61+
]
62+
},
5563
extras_require={
5664
'docs': ['sphinx<7', 'sphinx-autodoc-typehints>=1.2.0', 'sphinx-rtd-theme'],
5765
'installer': ['pyinstaller==4.10'],

0 commit comments

Comments
 (0)