Browse Source

another actions build attempt

Thomas Buck 3 years ago
parent
commit
53152d2cde
2 changed files with 37 additions and 7 deletions
  1. 10
    6
      dist/setup_mac.py
  2. 27
    1
      dist/setup_win.py

+ 10
- 6
dist/setup_mac.py View File

@@ -3,9 +3,11 @@
3 3
 
4 4
 from setuptools import setup
5 5
 
6
-APP = ['octotray.py']
7 6
 APP_NAME = "OctoTray"
8
-DATA_FILES = ['octotray_icon.png']
7
+APP = [ 'octotray.py' ]
8
+DATA_FILES = [ 'octotray_icon.png' ]
9
+VERSION="0.3.0"
10
+
9 11
 OPTIONS = {
10 12
     'argv_emulation': True,
11 13
     'iconfile': 'octotray_icon.png',
@@ -14,15 +16,17 @@ OPTIONS = {
14 16
         'CFBundleDisplayName': APP_NAME,
15 17
         'CFBundleGetInfoString': "Control OctoPrint instances from system tray",
16 18
         'CFBundleIdentifier': "de.xythobuz.octotray",
17
-        'CFBundleVersion': "0.3.0",
18
-        'CFBundleShortVersionString': "0.3.0",
19
+        'CFBundleVersion': VERSION,
20
+        'CFBundleShortVersionString': VERSION,
19 21
         'NSHumanReadableCopyright': u"Copyright © 2021, Thomas Buck, All Rights Reserved"
20 22
     }
21 23
 }
22 24
 
23 25
 setup(
26
+    name=APP_NAME,
27
+    version=VERSION,
24 28
     app=APP,
25 29
     data_files=DATA_FILES,
26
-    options={'py2app': OPTIONS},
27
-    setup_requires=['py2app'],
30
+    options={ 'py2app': OPTIONS },
31
+    setup_requires=[ 'py2app' ]
28 32
 )

+ 27
- 1
dist/setup_win.py View File

@@ -4,4 +4,30 @@
4 4
 import py2exe
5 5
 from distutils.core import setup
6 6
 
7
-setup(windows=[{"script": "octotray.py"}])
7
+APP_NAME = "OctoTray"
8
+APP = [ 'octotray.py' ]
9
+DATA_FILES = [ 'octotray_icon.png' ]
10
+VERSION="0.3"
11
+
12
+includes = [
13
+    "sip",
14
+    "PyQt5",
15
+    "PyQt5.QtCore",
16
+    "PyQt5.QtGui",
17
+    "PyQt5.QtNetwork",
18
+    "PyQt5.QtWidgets"
19
+]
20
+
21
+OPTIONS = {
22
+    "bundle_files": 1,
23
+    "includes": includes
24
+}
25
+
26
+setup(
27
+    name=APP_NAME,
28
+    version=VERSION,
29
+    windows=[ { "script": "octotray.py" } ],
30
+    data_files=DATA_FILES,
31
+    zipfile=None,
32
+    options={ 'py2exe': OPTIONS }
33
+)

Loading…
Cancel
Save