Skip to content

Commit 15984b0

Browse files
committed
Distribute Windows installer and bump version
1 parent 624b3c5 commit 15984b0

File tree

3 files changed

+30
-18
lines changed

3 files changed

+30
-18
lines changed

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ script:
77
deploy:
88
provider: pypi
99
user: mottosso
10-
distributions: "bdist"
10+
distributions: "bdist bdist_wininst"
1111
password:
1212
secure: c2n8K185Yz8u7y4zeqmZC+lkGIRqWJubHi/3SVdelQF+rgCUbbCg25B4TTAM0r1ESReuLixjVpU2UmuJ8LonmUsCicnBA0gbWfTfkIMICVZ+0+s3WYnlIAaO0rYj581vVwTXC/iN8nRepcjsczA0HThRp3lILB7ZjNxLRYivFRY=
1313
on:

PyQt5/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
os.environ['QT_QPA_PLATFORM_PLUGIN_PATH'] = plugin_path
3232

3333
# Expose versions
34-
version_info = (0, 1, 1) # Version of this release
34+
version_info = (0, 1, 2) # Version of this release
3535
version = "%s.%s.%s" % version_info
3636
__version__ = version
3737

setup.py

Lines changed: 28 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,32 @@
11
import os
2+
import sys
3+
24
from setuptools import setup, find_packages
35

6+
7+
def get_version():
8+
sys.path.insert(os.path.dirname(__file__))
9+
import PyQt5
10+
return PyQt5.__version__
11+
12+
13+
def get_package_data():
14+
package_data = dict()
15+
16+
package_data['PyQt5'] = list()
17+
for subdir in ("plugins/", "qml/", "uic/"):
18+
abspath = os.path.abspath("PyQt5/" + subdir)
19+
for root, dirs, files in os.walk(abspath):
20+
for f in files:
21+
fpath = os.path.join(root, f)
22+
relpath = os.path.relpath(fpath, abspath)
23+
relpath = relpath.replace("\\", "/")
24+
package_data['PyQt5'].append(subdir + relpath)
25+
26+
package_data['PyQt5'].extend(["*.exe", "*.dll", "*.pyd"])
27+
return package_data
28+
29+
430
classifiers = [
531
'Intended Audience :: Developers',
632
'License :: OSI Approved :: GNU General Public License v3 (GPLv3)',
@@ -12,23 +38,9 @@
1238
]
1339

1440

15-
package_data = dict()
16-
17-
package_data['PyQt5'] = list()
18-
for subdir in ("plugins/", "qml/", "uic/"):
19-
abspath = os.path.abspath("PyQt5/" + subdir)
20-
for root, dirs, files in os.walk(abspath):
21-
for f in files:
22-
fpath = os.path.join(root, f)
23-
relpath = os.path.relpath(fpath, abspath)
24-
relpath = relpath.replace("\\", "/")
25-
package_data['PyQt5'].append(subdir + relpath)
26-
27-
package_data['PyQt5'].extend(["*.exe", "*.dll", "*.pyd"])
28-
2941
setup(
3042
name='pypiqt5', # To avoid name-clash with existing PyQt5
31-
version="0.1.1",
43+
version=get_version(),
3244
description='PyQt5',
3345
long_description="pypiqt5",
3446
author='Marcus Ottosson',
@@ -38,5 +50,5 @@
3850
packages=find_packages(),
3951
zip_safe=False,
4052
classifiers=classifiers,
41-
package_data=package_data
53+
package_data=get_package_data()
4254
)

0 commit comments

Comments
 (0)