Update build_windows.yml #105
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build Windows | |
on: | |
push: | |
# Manual run | |
workflow_dispatch: | |
jobs: | |
build_windows: | |
runs-on: windows-latest | |
defaults: | |
run: | |
working-directory: ./python3-windows | |
strategy: | |
matrix: | |
env: | |
- { ARCH: win32, PYVER: 3.7.9 } | |
- { ARCH: amd64, PYVER: 3.7.9 } | |
- { ARCH: win32, PYVER: 3.8.10 } | |
- { ARCH: amd64, PYVER: 3.8.10 } | |
- { ARCH: win32, PYVER: 3.9.13 } | |
- { ARCH: amd64, PYVER: 3.9.13 } | |
- { ARCH: win32, PYVER: 3.10.11 } | |
- { ARCH: amd64, PYVER: 3.10.11 } | |
- { ARCH: win32, PYVER: 3.11.9 } | |
- { ARCH: amd64, PYVER: 3.11.9 } | |
- { ARCH: win32, PYVER: 3.12.7 } | |
- { ARCH: amd64, PYVER: 3.12.7 } | |
- { ARCH: win32, PYVER: 3.13.0 } | |
- { ARCH: amd64, PYVER: 3.13.0 } | |
steps: | |
- name: Checkout main repo | |
uses: actions/checkout@v4 | |
- name: Build Python | |
shell: cmd | |
run: | | |
@echo off | |
:: Set env parameters | |
set ARCH=${{ matrix.env.ARCH }} | |
set PYVER=${{ matrix.env.PYVER }} | |
:: Run the build script | |
build.bat | |
- name: Create package | |
id: create_package | |
shell: cmd | |
run: | | |
cd ${{ matrix.env.ARCH }}\embeddable\ | |
7z a -tzip python3-windows-${{ matrix.env.PYVER }}-${{ matrix.env.ARCH }}.zip * -r | |
- name: Save build | |
uses: actions/upload-artifact@v4 | |
with: | |
name: python3-windows\${{ matrix.env.ARCH }}\embeddable\python3-windows-${{ matrix.env.PYVER }}-${{ matrix.env.ARCH }}.zip | |
path: python3-windows\${{ matrix.env.ARCH }}\embeddable\python3-windows-${{ matrix.env.PYVER }}-${{ matrix.env.ARCH }}.zip | |
if-no-files-found: error | |
- name: Publish to Digital Ocean | |
uses: BetaHuhn/do-spaces-action@v2 | |
with: | |
access_key: ${{ secrets.ACCESS_KEY}} | |
secret_key: ${{ secrets.SECRET_KEY }} | |
space_name: ${{ secrets.SPACE_NAME }} | |
space_region: ${{ secrets.SPACE_REGION }} | |
source: python3-windows\${{ matrix.env.ARCH }}\embeddable\python3-windows-${{ matrix.env.PYVER }}-${{ matrix.env.ARCH }}.zip |