Skip to content

Blocksparse Stagewise KKT Solver #42

Blocksparse Stagewise KKT Solver

Blocksparse Stagewise KKT Solver #42

Workflow file for this run

name: Build Octave interface and upload to release
on:
pull_request:
push:
branches:
- main
release:
types:
- published
jobs:
build_test_release:
name: package, install and release Octave interface
strategy:
fail-fast: false
matrix:
os: [ ubuntu-latest, macos-13, macos-14, windows-latest ]
runs-on: ${{ matrix.os }}
steps:
- name: Check out repository
uses: actions/checkout@v3
with:
submodules: 'recursive'
- name: Install Octave (Linux)
if: runner.os == 'Linux'
run: |
sudo apt update
sudo apt install --no-install-recommends octave liboctave-dev
- name: Install Octave (macOS)
if: runner.os == 'macOS'
run: brew install octave
- name: Install Octave (Windows)
if: runner.os == 'Windows'
run: choco install octave.portable
- name: Package interface
working-directory: interfaces/octave
run: octave package_piqp.m
- name: Install pkg
working-directory: interfaces/octave
run: octave --eval "pkg install piqp-octave.tar.gz"
- name: Load pkg
working-directory: interfaces/octave
run: octave --eval "pkg load piqp; piqp('sparse')"
- name: Upload artifact
if: runner.os == 'Linux'
uses: actions/upload-artifact@v3
with:
path: ./interfaces/octave/piqp-octave.tar.gz
- name: Upload tarballs
if: runner.os == 'Linux' && github.event_name == 'release' && github.event.action == 'published'
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./interfaces/octave/piqp-octave.tar.gz
asset_name: piqp-octave.tar.gz
asset_content_type: application/gzip