Skip to content

Commit 6c8ac17

Browse files
committed
adding push to testpypi stage for windows wheels
1 parent 5afba98 commit 6c8ac17

File tree

1 file changed

+24
-55
lines changed

1 file changed

+24
-55
lines changed

.github/workflows/build_wheels.yml

Lines changed: 24 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -97,39 +97,7 @@ jobs:
9797
&& cmake --install build --config Release
9898
&& ls install/lib
9999
&& cat install/python_installer/setup.py
100-
# && cp -r install ${{github.workspace}}\python_installer
101-
# && ls ${{github.workspace}}
102-
# && sed -i "s/.*Iconv_INCLUDE_DIR.*/Iconv_INCLUDE_DIR:PATH=C:/vcpkg/installed/x64-windows-static-md/include" build/CMakeCache.txt
103-
# && (Get-Content build/CMakeCache.txt) | ForEach-Object {
104-
# if ($_ -match ".*Iconv_INCLUDE_DIR.*") {
105-
# "Iconv_INCLUDE_DIR:PATH=C:/vcpkg/installed/x64-windows-static-md/include"
106-
# } else {
107-
# $_
108-
# }
109-
# } | Set-Content ./build/CMakeCache.txt
110-
# && Add-Content -Path ./build/CMakeCache.txt -Value "Iconv_INCLUDE_DIR:PATH=C:/vcpkg/installed/x64-windows-static-md/include"
111-
112-
113-
114-
# && cp C:/vcpkg/installed/x64-windows-static-md/include/iconv.h C:/vcpkg/installed/x64-windows-static-md/include/libxml2/libxml/
115-
# && cp C:/vcpkg/installed/x64-windows-static-md/include/iconv.h ./source/structures/
116-
117-
# - name: test pyuda on windows
118-
# if: runner.os == 'Windows'
119-
# env:
120-
# UDA_DIR: ${{github.workspace}}\install
121-
# EXTLIB_INSTALL_DIR: ${{github.workspace}}\extlib\install
122-
# run: >
123-
# (gcm python3).Path &&
124-
# #Set-Content -Path "C:\hostedtoolcache\windows\Python\3.9.13\x64\Lib\distutils\distutils.cfg" -Value "[build]`ncompiler = mingw32" &&
125-
# python3 -m venv ${{github.workspace}}/venv &&
126-
# ls ${{github.workspace}}/venv &&
127-
# ${{github.workspace}}/venv/Scripts/Activate.ps1 &&
128-
# pip3 install --upgrade pip wheel &&
129-
# pip3 install Cython numpy six wheel &&
130-
# CXX=g++ CC=gcc python3 ${{github.workspace}}\install\python_installer\setup.py bdist_wheel
131-
#
132-
100+
133101
134102
- name: build windows wheels
135103
if: runner.OS == 'Windows'
@@ -140,7 +108,8 @@ jobs:
140108
env:
141109
CIBW_ARCHS: ${{matrix.build-platform[1]}}
142110
CIBW_PLATFORM: windows
143-
CIBW_BUILD: cp31*-${{matrix.build-platform[2]}}
111+
CIBW_BUILD: cp3*-${{matrix.build-platform[2]}}
112+
CIBW_SKIP: cp36* cp37*
144113
CIBW_REPAIR_WHEEL_COMMAND_WINDOWS: "delvewheel repair -w {dest_dir} {wheel} --add-path ${{github.workspace}}/install/lib"
145114
CIBW_BEFORE_BUILD_WINDOWS: "pip install delvewheel"
146115

@@ -260,24 +229,24 @@ jobs:
260229
name: cibw-wheels-${{ matrix.os }}-${{ strategy.job-index }}
261230
path: ./wheelhouse/*.whl
262231

263-
# upload_pypi:
264-
# needs: build_wheels
265-
# runs-on: ubuntu-latest
266-
# environment:
267-
# name: testpypi
268-
# # url: https://test.pypi.org/project/ukaea_pyuda/
269-
# permissions:
270-
# id-token: write
271-
# # if: github.event_name == 'release' && github.event.action == 'published'
272-
# # if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
273-
# steps:
274-
# - uses: actions/download-artifact@v4
275-
# with:
276-
# # unpacks all CIBW artifacts into dist/
277-
# pattern: cibw-*
278-
# path: dist
279-
# merge-multiple: true
280-
#
281-
# - uses: pypa/gh-action-pypi-publish@release/v1
282-
# with:
283-
# repository-url: https://test.pypi.org/legacy/
232+
upload_pypi:
233+
needs: build_wheels
234+
runs-on: ubuntu-latest
235+
environment:
236+
name: testpypi
237+
# url: https://test.pypi.org/project/ukaea_pyuda/
238+
permissions:
239+
id-token: write
240+
# if: github.event_name == 'release' && github.event.action == 'published'
241+
# if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
242+
steps:
243+
- uses: actions/download-artifact@v4
244+
with:
245+
# unpacks all CIBW artifacts into dist/
246+
pattern: cibw-*
247+
path: dist
248+
merge-multiple: true
249+
250+
- uses: pypa/gh-action-pypi-publish@release/v1
251+
with:
252+
repository-url: https://test.pypi.org/legacy/

0 commit comments

Comments
 (0)