@@ -42,44 +42,24 @@ jobs:
4242 sudo apt-get install -y libcurl4-openssl-dev libssh2-1-dev libharfbuzz-dev libfribidi-dev gh &&
4343 sudo rm -rf /var/lib/apt/lists/*
4444 - name : Configuration Information
45- if : runner.os == 'Linux' || runner.os == 'macOS'
45+ shell : bash
4646 run : |
47- mkdir ${R_LIBS}
48- c++ --version
47+ mkdir -p "$R_LIBS"
4948 cmake --version
49+ if [[ "$RUNNER_OS" == "Windows" ]]; then
50+ g++ --version
51+ else
52+ c++ --version
53+ fi
5054 which R
5155 R --version
52- - name : Configuration Information (Windows)
53- if : startsWith(matrix.os, 'windows')
54- shell : pwsh
55- run : |
56- New-Item -ItemType Directory -Force -Path "$env:R_LIBS" | Out-Null
57- g++ --version
58- cmake --version
59- Get-Command R.exe
60- R.exe --version
6156 - name : Install R packages
62- if : runner.os == 'Linux' || runner.os == 'macOS'
63- run : |
64- R -e "install.packages(c('remotes'), lib=c('${R_LIBS}'), repos='https://cloud.r-project.org/')"
65- - name : Install R packages (Windows)
66- if : startsWith(matrix.os, 'windows')
67- shell : pwsh
57+ shell : bash
6858 run : |
69- Rscript -e "lib <- Sys.getenv('R_LIBS'); lib <- normalizePath(lib, winslash='/', mustWork=FALSE); dir.create(lib, recursive=TRUE, showWarnings=FALSE); install.packages('remotes', lib=lib, repos='https://cloud.r-project.org/')"
70- Rscript.exe -e "install.packages(c('remotes', 'desc'), repos='https://cloud.r-project.org/')"
59+ R -e "install.packages(c('remotes'), lib=Sys.getenv('R_LIBS'), repos='https://cloud.r-project.org/')"
7160 - name : Build and test
72- if : runner.os == 'Linux' || runner.os == 'macOS'
73- run : |
74- set -x
75- R -e "remotes::install_git(c('.'), lib=c('${R_LIBS}'), configure.vars=c('"MAKEJ=2"'))"
76- env :
77- ITK_GLOBAL_DEFAULT_NUMBER_OF_THREADS : 2
78- - name : Build and test (Windows)
79- if : startsWith(matrix.os, 'windows')
80- shell : pwsh
61+ shell : bash
8162 env :
8263 ITK_GLOBAL_DEFAULT_NUMBER_OF_THREADS : 2
8364 run : |
84- $env:MAKEJ="3"
85- Rcmd.exe INSTALL --build .
65+ R -e "remotes::install_git(c('.'), lib=Sys.getenv('R_LIBS'), configure.vars=c('MAKEJ=2'))"
0 commit comments