diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml index a0c9d50..d7f0427 100644 --- a/.github/workflows/R-CMD-check.yaml +++ b/.github/workflows/R-CMD-check.yaml @@ -22,6 +22,7 @@ jobs: - {os: macos-latest, r: 'release'} - {os: macos-latest, r: 'oldrel'} + - {os: windows-11-arm } - {os: windows-latest, r: 'devel'} - {os: windows-latest, r: 'release'} - {os: windows-latest, r: 'oldrel'} @@ -47,16 +48,48 @@ jobs: - uses: r-lib/actions/setup-pandoc@v2 - uses: r-lib/actions/setup-r@v2 + if: matrix.config.os != 'windows-11-arm' with: r-version: ${{ matrix.config.r }} rtools-version: ${{ matrix.config.rtools }} http-user-agent: ${{ matrix.config.http-user-agent }} use-public-rspm: true + - name: Install R & RTools (ARM64) + if: matrix.config.os == 'windows-11-arm' + run: | + $url = "https://www.r-project.org/nosvn/winutf8/aarch64/R-4-signed/R-4.5.0-aarch64.exe" + Invoke-WebRequest ` + -Uri https://www.r-project.org/nosvn/winutf8/aarch64/R-4-signed/R-4.5.0-aarch64.exe ` + -OutFile R-4.5.0-aarch64.exe + Start-Process ` + -FilePath R-4.5.0-aarch64.exe ` + -ArgumentList "/INSTALL /VERYSILENT /SUPPRESSMSGBOXES" -Wait + + Invoke-WebRequest ` + -Uri https://github.com/r-hub/rtools45/releases/download/latest/rtools45-aarch64.exe ` + -OutFile "rtools45-aarch64.exe" + Start-Process ` + -FilePath "rtools45-aarch64.exe" ` + -ArgumentList "/INSTALL /VERYSILENT /SUPPRESSMSGBOXES" -Wait + + echo "C:/rtools45-aarch64/usr/bin;C:/rtools45-aarch64/aarch64-w64-mingw32.static.posix/bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8 + echo "C:\Program Files\R-aarch64\R-4.5.0\bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8 + Remove-Item -Path "R-4.5.0-aarch64.exe" + Remove-Item -Path "rtools45-aarch64.exe" + + - name: Install Dependencies (ARM64) + if: matrix.config.os == 'windows-11-arm' + run: | + install.packages(c("tinytest", "knitr", "rmarkdown", "rcmdcheck"), + repos = c("https://r-lib.r-universe.dev", "https://cloud.r-project.org"), + Ncpus = 4); + shell: Rscript {0} + - uses: r-lib/actions/setup-r-dependencies@v2 + if: matrix.config.os != 'windows-11-arm' with: - extra-packages: | - any::rcmdcheck + extra-packages: any::rcmdcheck needs: check - uses: r-lib/actions/check-r-package@v2