Repository navigation
Merge pull request #3 from Reflct/develop #20
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: CI | |
| on: | |
| push: | |
| branches: [master, develop] | |
| pull_request: | |
| permissions: | |
| contents: read | |
| jobs: | |
| test: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [ubuntu-latest, macos-latest, windows-latest] | |
| python-version: ["3.10", "3.11", "3.12", "3.13"] | |
| runs-on: ${{ matrix.os }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| cache: pip | |
| - name: Install FFmpeg (Ubuntu) | |
| if: runner.os == 'Linux' | |
| run: sudo apt-get update && sudo apt-get install --yes ffmpeg | |
| - name: Install FFmpeg (macOS) | |
| if: runner.os == 'macOS' | |
| run: brew install ffmpeg | |
| - name: Install FFmpeg (Windows) | |
| if: runner.os == 'Windows' | |
| run: choco install ffmpeg --yes --no-progress | |
| - name: Install package and test dependencies | |
| run: python -m pip install --upgrade pip && python -m pip install -r requirements.txt | |
| - name: Run tests | |
| run: python -m pytest -q | |
| - name: Build wheel | |
| run: python -m pip wheel . --no-deps --wheel-dir dist | |
| minimum-textual: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.10" | |
| cache: pip | |
| - name: Install FFmpeg | |
| run: sudo apt-get update && sudo apt-get install --yes ffmpeg | |
| - name: Install minimum supported Textual | |
| run: >- | |
| python -m pip install --upgrade pip && | |
| python -m pip install -e . -r tests/requirements.txt "textual==5.0.0" && | |
| python -m pip check | |
| - name: Run tests at the minimum Textual version | |
| run: python -m pytest -q | |
| package: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.13" | |
| cache: pip | |
| - name: Install build tooling and FFmpeg | |
| run: | | |
| sudo apt-get update && sudo apt-get install --yes ffmpeg | |
| python -m pip install --upgrade pip build | |
| - name: Build distribution artifacts | |
| run: python -m build | |
| - name: Smoke test installed wheel outside the checkout | |
| run: | | |
| python -m venv "$RUNNER_TEMP/wheel-smoke" | |
| "$RUNNER_TEMP/wheel-smoke/bin/python" -m pip install dist/*.whl | |
| cd "$RUNNER_TEMP" | |
| "$RUNNER_TEMP/wheel-smoke/bin/python" -c "import sharp_frames; from sharp_frames.ui.components.raster_preview import RasterImagePreview; print(sharp_frames.__version__)" | |
| "$RUNNER_TEMP/wheel-smoke/bin/sharp-frames" --help |