4141 architecture : ' x64'
4242 - name : Build Rust Library
4343 run : |
44- rustup target add x86_64-pc-windows-msvc
4544 cargo build --target x86_64-pc-windows-msvc --release
4645 - name : Setup Example dir
4746 run : |
@@ -54,19 +53,24 @@ jobs:
5453 filename : ' ../Rules.zip'
5554 directory : ' Example'
5655 path : ' Rules'
56+ - name : create zip file for pyd file -- this allows the name to indicate arch, python version etc but unzipped it is correctly named
57+ uses : thedoctor0/zip-release@0.7.5
58+ with :
59+ type : ' zip'
60+ filename : ' ../libmathcat_py-64-3.11-win.zip'
61+ directory : ' Example'
62+ path : ' libmathcat_py.pyd'
5763 # build the test after zipping up "Rules" because the test will unzip the files needed for the test
5864 #
5965 # - name: test build
6066 # run: |
6167 # cd Example
6268 # python test.py
63- - name : rename pyd file
64- run : mv Example/libmathcat_py.pyd Example/libmathcat_py-64-3.11.pyd
6569 - name : Upload 64 bit pyd file
6670 uses : actions/upload-artifact@v4
6771 with :
68- name : libmathcat_py-64-3.11.pyd
69- path : Example/ libmathcat_py-64-3.11.pyd
72+ name : libmathcat_py-64-3.11-win.zip
73+ path : libmathcat_py-64-3.11-win.zip
7074 compression-level : 0
7175 retention-days : 1
7276 - name : Upload Rules.zip
@@ -113,29 +117,41 @@ jobs:
113117 - name : Set up Python
114118 uses : actions/setup-python@v4
115119 with :
116- python-version : 3.11
117- - name : Download MathCAT addons dir
118- uses : actions/download-artifact@v4
119- with :
120- name : libmathcat_py-64-3.11.pyd
121- - shell : bash
122- run : |
123- cp -r MathCAT addon/globalPlugins
120+ python-version : 3.11 # needed for scons
121+
124122 - name : Install scons dependencies
125123 run : |
126124 pip install scons markdown
127125 sudo apt update
128126 sudo apt install gettext
129- - name : Run scons to build addon
127+ - name : Run scons to build . addon file
130128 run : |
131- scons
132- - name : copy standalone library so it has a meaningful name
133- run : |
134- cp addon/globalPlugins/MathCAT/libmathcat_py.pyd libmathcat_py-32-3.11.pyd
129+ scons
130+
131+ # download the previous build artifacts and put them in their proper places
135132 - name : Download 64 bit build
133+ uses : actions/download-artifact@v4
134+ with :
135+ name : libmathcat_py-64-3.11-win.zip
136+ - name : Download Rules.zip
137+ uses : actions/download-artifact@v4
138+ with :
139+ name : Rules.zip
140+ - name : Download MathCAT addons dir
136141 uses : actions/download-artifact@v4
137142 with :
138143 name : MathCAT_addons
144+ - shell : bash
145+ run : cp -r MathCAT addon/globalPlugins
146+ - name : create zip file for standalone pyd file -- this allows the name to indicate arch, python version etc but unzipped it is correctly named
147+ uses : thedoctor0/zip-release@0.7.5
148+ with :
149+ type : ' zip'
150+ filename : ' ../../../libmathcat_py-32-3.11-win.zip'
151+ directory : ' addon/globalPlugins/MathCAT'
152+ path : ' libmathcat_py.pyd'
153+
154+ # finally, put the files into the release
139155 - name : Automatic release
140156 uses : marvinpinto/action-automatic-releases@latest
141157 with :
@@ -145,6 +161,6 @@ jobs:
145161 title : Development Build
146162 files : |
147163 *.nvda-addon
148- libmathcat_py-32-3.11.pyd
149- libmathcat_py-64-3.11.pyd
164+ libmathcat_py-32-3.11-win.zip
165+ libmathcat_py-64-3.11-win.zip
150166 Rules.zip
0 commit comments