Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
osqp / .github / workflows / build.yml
Size: Mime:
name: Build

on: [push, pull_request]

jobs:
  build_wheels:
    name: Build wheel on ${{ matrix.os }}
    runs-on: ${{ matrix.os }}
    strategy:
      fail-fast: false
      matrix:
        os: [ubuntu-latest, macos-latest, windows-latest]

    steps:
    - uses: actions/checkout@master
      with:
        submodules: 'recursive'

    - name: Add msbuild to PATH
      uses: microsoft/setup-msbuild@v1.0.2
      if: startsWith(matrix.os,'windows')

    - name: Add Windows SDK
      shell: cmd
      if: startsWith(matrix.os,'windows')
      run: |
        choco install windows-sdk-8.1

    - uses: actions/setup-python@v2
      name: Install Python
      with:
        python-version: '3.9'

    - name: Build wheels
      run: |
        python -m pip install --upgrade pip
        python -m pip install --upgrade build
        python -m pip install cibuildwheel
        python -m cibuildwheel --output-dir wheelhouse

    - name: Build source
      if: startsWith(matrix.os, 'ubuntu')
      run: |
        python -m build . --sdist --outdir wheelhouse

    - name: Release to pypi
      if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags')
      env:
        TWINE_USERNAME: __token__
        TWINE_PASSWORD: ${{ secrets.pypi_password }}
      run: |
        python -m pip install --upgrade twine
        twine upload wheelhouse/*

    - name: Upload artifacts to github
      uses: actions/upload-artifact@v1
      with:
        name: wheels
        path: ./wheelhouse