on: workflow_call: inputs: python-version: required: false type: string default: '["3.12"]' os: required: false type: string default: ubuntu-latest fail-fast: required: false type: boolean default: false ref: required: false type: string default: ${{ github.sha }} permissions: contents: read jobs: tutorials: runs-on: ${{ inputs.os }} continue-on-error: true strategy: fail-fast: ${{ inputs.fail-fast }} matrix: python-version: ${{ fromJSON(inputs.python-version) }} steps: - name: Checkout repository uses: actions/checkout@v6 with: ref: ${{ inputs.ref }} - name: Set pixi environment name id: pixi-env shell: bash run: echo "name=py$(echo '${{ matrix.python-version }}' | tr -d '.')" >> $GITHUB_OUTPUT - name: Setup pixi uses: prefix-dev/setup-pixi@v0.9.6 with: pixi-version: v0.40.0 cache: true environments: ${{ steps.pixi-env.outputs.name }} - name: Install kornia run: pixi run -e ${{ steps.pixi-env.outputs.name }} install - uses: actions/checkout@v6 with: repository: "kornia/tutorials" path: "tutorials-repo/" - name: Install dependencies working-directory: ./tutorials-repo/ env: PIP_NO_CACHE_DIR: "1" PIP_INDEX_URL: "https://download.pytorch.org/whl/cpu" PIP_EXTRA_INDEX_URL: "https://pypi.org/simple" run: make setup - name: Install local kornia run: pip install -e . --no-deps - name: Check deps working-directory: ./tutorials-repo/ run: make check-deps - name: Generate tutorials working-directory: ./tutorials-repo/ run: make generate - name: Run tutorials working-directory: ./tutorials-repo/ run: make execute