Skip to content

Python: RandomForest conforms to sklearn Estimator interface #122

Python: RandomForest conforms to sklearn Estimator interface

Python: RandomForest conforms to sklearn Estimator interface #122

Workflow file for this run

name: R package
on:
workflow_dispatch:
push:
tags:
- "[0-9]+.[0-9]+.[0-9]+"
- "[0-9]+.[0-9]+.[0-9]+-rc[1-9]+"
- "[0-9]+.[0-9]+.[0-9]+rc[1-9]+"
- "[0-9]+.[0-9]+.[0-9]+-b[1-9]+"
- "[0-9]+.[0-9]+.[0-9]+b[1-9]+"
pull_request:
paths:
- ".github/workflows/R.yaml"
- "src/**"
- "R/**"
jobs:
test:
runs-on: ${{ matrix.config.os }}
name: ${{ matrix.config.os }} (${{ matrix.config.r }})
strategy:
fail-fast: false
matrix:
config:
- { os: windows-latest, r: "release" }
- { os: macOS-latest, r: "release" }
- {
os: ubuntu-22.04,
r: "release",
rspm: "https://packagemanager.rstudio.com/cran/__linux__/focal/latest",
}
- {
os: ubuntu-22.04,
r: "3.6.3",
rspm: "https://packagemanager.rstudio.com/cran/__linux__/focal/latest",
}
env:
R_REMOTES_NO_ERRORS_FROM_WARNINGS: true
RSPM: ${{ matrix.config.rspm }}
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
submodules: recursive
- name: Setup R
uses: r-lib/actions/setup-r@v2
with:
r-version: ${{ matrix.config.r }}
- name: Install R dependencies
uses: r-lib/actions/setup-r-dependencies@v2
with:
cache-version: 2
working-directory: R/
extra-packages: any::rcmdcheck
- name: Run tests
uses: r-lib/actions/check-r-package@v2
with:
args: 'c("--no-manual", "--as-cran", "--no-multiarch")'
working-directory: R/
build:
name: R build
runs-on: ubuntu-latest
needs: [test]
if: github.event_name == 'push' && github.ref_type == 'tag'
steps:
- name: Checkout
uses: actions/checkout@v3
with:
submodules: recursive
- name: Build package
run: R CMD build R/
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: Rforestry
path: Rforestry*.tar.gz