diff --git a/.github/workflows/debian-cran-check.yaml b/.github/workflows/debian-cran-check.yaml new file mode 100644 index 0000000..517eb73 --- /dev/null +++ b/.github/workflows/debian-cran-check.yaml @@ -0,0 +1,32 @@ +# CRAN Debian incoming checks +# Uses the official Debian-based CRAN check environment +name: Debian CRAN Check + +on: + push: + branches: [main, master] + pull_request: + branches: [main, master] + +jobs: + check-cran-debian: + runs-on: ubuntu-latest + permissions: + contents: read + container: + image: ghcr.io/r-devel/rcheckserver/debian:latest + + steps: + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Install package dependencies + run: | + R -e 'install.packages("remotes", repos = "https://cloud.r-project.org")' + R -e 'remotes::install_deps(dependencies = TRUE)' + + - name: Run R CMD check with --as-cran + run: | + cd .. + R CMD build --no-manual ${GITHUB_REPOSITORY#*/} + R CMD check --as-cran ${GITHUB_REPOSITORY#*/}*.tar.gz