Skip to content

Add cross-platform PR CI workflow for master with R CMD check + animl_env Python setup - #129

Merged
tkswanson merged 11 commits into
devfrom
copilot/setup-github-actions-ci-cd
Jul 31, 2026
Merged

Add cross-platform PR CI workflow for master with R CMD check + animl_env Python setup#129
tkswanson merged 11 commits into
devfrom
copilot/setup-github-actions-ci-cd

Conversation

Copilot AI commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

This PR adds a GitHub Actions CI workflow for animl-r pull requests targeting master, with full package checks and test execution via rcmdcheck. It also provisions the required reticulate-accessible Python environment (animl_env) with animl-py installed.

  • Trigger + execution matrix

    • New workflow: .github/workflows/R-CMD-check.yaml
    • Runs only on pull_request to master
    • Matrix across ubuntu-latest, macos-latest, and windows-latest
    • Uses R release
  • Python/reticulate dependency bootstrap

    • Sets up Python 3.12
    • Creates virtualenv at ~/.virtualenvs/animl_env
    • Installs animl-py into that env
    • Exposes env to reticulate via:
      • WORKON_HOME=~/.virtualenvs
      • RETICULATE_PYTHON=<animl_env python>
  • R package checks + failure artifacts

    • Installs R dependencies (including rcmdcheck)
    • Runs rcmdcheck::rcmdcheck(..., check_dir = "check")
    • Uploads check/ artifacts on failure for triage
  • Workflow hardening

    • Adds explicit minimal token scope:
      • permissions: { contents: read }
on:
  pull_request:
    branches: [master]

permissions:
  contents: read

- uses: actions/setup-python@v5
  with:
    python-version: '3.12'

- name: Create animl_env and install animl-py
  run: |
    VENV_DIR="$HOME/.virtualenvs/animl_env"
    python -m venv "$VENV_DIR"
    "$VENV_DIR/bin/python" -m pip install --upgrade pip
    "$VENV_DIR/bin/python" -m pip install animl-py
    echo "WORKON_HOME=$HOME/.virtualenvs" >> "$GITHUB_ENV"
    echo "RETICULATE_PYTHON=$VENV_DIR/bin/python" >> "$GITHUB_ENV"

Copilot AI changed the title [WIP] Set up GitHub Actions CI/CD workflow for R CMD CHECK and tests Add cross-platform PR CI workflow for master with R CMD check + animl_env Python setup Jul 31, 2026
Copilot AI requested a review from tkswanson July 31, 2026 17:33
@tkswanson
tkswanson marked this pull request as ready for review July 31, 2026 18:00
Copilot stopped work on behalf of tkswanson due to an error July 31, 2026 19:16
Copilot stopped work on behalf of tkswanson due to an error July 31, 2026 19:26
@tkswanson
tkswanson changed the base branch from master to dev July 31, 2026 19:46
@tkswanson
tkswanson merged commit 08d9323 into dev Jul 31, 2026
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants