Fix Python package metadata #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: | |
| pull_request: | |
| push: | |
| branches: | |
| - main | |
| permissions: | |
| contents: read | |
| jobs: | |
| repository: | |
| name: Repository checks | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check out repository | |
| uses: actions/checkout@v6 | |
| - name: Check repository layout | |
| shell: bash | |
| run: | | |
| test -f README.md | |
| test -f LICENSE.md | |
| test -f R/rd2d/DESCRIPTION | |
| r-check: | |
| name: R CMD check | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check out repository | |
| uses: actions/checkout@v6 | |
| - name: Set up R | |
| uses: r-lib/actions/setup-r@v2 | |
| with: | |
| use-public-rspm: true | |
| - name: Set up Pandoc | |
| uses: r-lib/actions/setup-pandoc@v2 | |
| - name: Install R dependencies | |
| run: | | |
| repos <- c(RSPM = Sys.getenv("RSPM"), CRAN = "https://cloud.r-project.org") | |
| install.packages(c("MASS", "expm", "ggplot2", "testthat"), repos = repos) | |
| shell: Rscript {0} | |
| - name: Build R source package | |
| run: R CMD build R/rd2d | |
| - name: Check R package | |
| run: R CMD check rd2d_*.tar.gz --no-manual | |
| python-check: | |
| name: Python package tests | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check out repository | |
| uses: actions/checkout@v6 | |
| - name: Set up Python | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.12" | |
| - name: Install Python package | |
| run: python -m pip install -e "Python/rd2d[test,plots]" | |
| - name: Test Python package | |
| working-directory: Python/rd2d | |
| run: python -m pytest |