Add Pixi Environment Setup for brian2wasm #7
Workflow file for this run
This file contains hidden or 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: Test PR on Linux and macOS | |
| on: | |
| pull_request: | |
| branches: | |
| - main | |
| jobs: | |
| test: | |
| name: Test on ${{ matrix.os }} | |
| runs-on: ${{ matrix.os }} | |
| timeout-minutes: 30 | |
| strategy: | |
| matrix: | |
| os: [ubuntu-latest, macos-latest] | |
| fail-fast: false | |
| steps: | |
| # Clone the repository | |
| - name: Clone repository | |
| uses: actions/checkout@v4 | |
| with: | |
| ref: ${{github.event.pull_request.head.ref}} | |
| repository: ${{github.event.pull_request.head.repo.full_name}} | |
| # Install Pixi | |
| - name: Install pixi | |
| uses: prefix-dev/setup-pixi@v0.8.0 | |
| with: | |
| cache: false | |
| # Verify Pixi installation | |
| - name: Verify Pixi version | |
| run: pixi --version | |
| # Run pixi install | |
| - name: Install dependencies | |
| run: pixi install --locked | |
| # Run setup | |
| - name: Run setup | |
| run: pixi run setup | |
| # Check Dependencies | |
| - name: Check dependencies | |
| run: which emcc emrun brian2wasm emsdk | |
| shell: pixi run bash -e {0} | |
| # Run an example and check output | |
| - name: Run example and verify output files | |
| run: | | |
| cd examples | |
| python -m brian2wasm brunel_hakim1999.py --no-server | |
| ls brunel_hakim1999/{brian.js,index.html,wasm_module.{js,wasm},worker.js} | |
| shell: pixi run bash -e {0} |