Add py check wf #1
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: Version Check | |
| on: | |
| workflow_dispatch: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| jobs: | |
| check-versions: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Install yq for toml parsing | |
| run: pip install yq | |
| - name: Read Python versions from pyproject.toml | |
| id: versions | |
| run: | | |
| PYTHON_VERSION=$(tomlq -r .tool.poetry.dependencies.python < pyproject.toml | tr -d '"') | |
| MATPLOTLIB_VERSION=$(tomlq -r .tool.poetry.dependencies.matplotlib < pyproject.toml | tr -d '"') | |
| echo "python_version=$PYTHON_VERSION" >> $GITHUB_OUTPUT | |
| echo "matplotlib_version=$MATPLOTLIB_VERSION" >> $GITHUB_OUTPUT | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: ${{ steps.versions.outputs.python_version }} |