Skip to content

Commit 9358e38

Browse files
committed
Force installing ggplot2 version 3.5.2 to avoid CI errors
1 parent 0b6c6e2 commit 9358e38

File tree

1 file changed

+30
-15
lines changed

1 file changed

+30
-15
lines changed

.github/workflows/pkgdown.yaml

Lines changed: 30 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -33,31 +33,46 @@ jobs:
3333
- name: Checkout repository
3434
uses: actions/checkout@v4
3535

36+
- name: Install system dependencies for GEOS, GDAL, PROJ
37+
run: |
38+
sudo apt-get update
39+
sudo apt-get install -y \
40+
libgeos-dev \
41+
libgdal-dev \
42+
libproj-dev
43+
3644
- name: Set up Pandoc
3745
uses: r-lib/actions/setup-pandoc@v2
38-
46+
3947
- name: Set up R
4048
uses: r-lib/actions/setup-r@v2
4149
with:
4250
use-public-rspm: true
4351

44-
- name: Ensure remotes is installed
45-
run: Rscript -e 'if (!requireNamespace("remotes", quietly = TRUE)) install.packages("remotes")'
52+
- name: Install necessary packages
53+
run: |
54+
Rscript -e 'install.packages(c("rcmdcheck", "remotes", "Rcpp", "lubridate", "RcppArmadillo", "tidyverse", "terra", "sf", "coda", "foreach", "fs", "tibble", "dplyr", "future", "future.apply", "rlang", "DT", "kableExtra", "knitr", "httr", "foreign", "tidyselect", "purrr", "rvest", "stringr", "rmarkdown", "archive", "magrittr", "arrow", "caret", "colorRamps", "devtools", "doParallel", "ecospat", "fastmatch", "float", "furrr", "gdata", "ggbreak", "ggnewscale", "ggtext", "gridtext", "gt", "gtools", "janitor", "jsonify", "lobstr", "ncdf4", "pak", "pbapply", "png", "quarto", "R.utils", "RCurl", "Rfast", "rgbif", "RNetCDF", "scales", "rworldmap", "smoothr", "snow", "spelling", "testthat", "writexl", "pkgdown", "lintr", "sessioninfo", "cowplot", "ggpubr", "ggExtra", "zip", "tidyterra", "exactextractr", "blockCV", "renv"), Ncpus = parallel::detectCores())'
4655
47-
- name: Force install ggplot2 3.5.2
48-
run: Rscript -e 'remotes::install_version("ggplot2", version = "3.5.2")'
56+
- name: Install packages from github
57+
run: |
58+
Rscript -e 'remotes::install_github(c("elgabbas/ecokit", "hmsc-r/HMSC", "EmilHvitfeldt/paletteer", "YuLab-SMU/ggtree", "babaknaimi/sdm"))'
4959
50-
- name: Force install scales 1.3.0
51-
run: Rscript -e 'remotes::install_version("scales", version = "1.3.0")'
60+
# - name: Install some pinned package versions
61+
# run: |
62+
# Rscript -e 'renv::install(c("scales@1.3.0", "pkgdown@2.0.7", "lintr@3.0.0", "sessioninfo@1.2.2", "ggplot2@3.5.2", "cowplot@1.1.3", "ggpubr@0.6.0", "ggExtra@0.10.1"))'
5263

53-
- name: Force install pkgdown 2.0.7
54-
run: Rscript -e 'remotes::install_version("pkgdown", version = "2.0.7")'
55-
56-
- name: Install dependencies
57-
uses: r-lib/actions/setup-r-dependencies@v2
58-
with:
59-
extra-packages: any::pkgdown, local::.
60-
needs: website
64+
- name: Install remaining dependencies
65+
run: |
66+
Rscript -e 'remotes::install_deps(dependencies=c("Depends", "Imports"), upgrade = "never")'
67+
Rscript -e 'renv::install("ggplot2@3.5.2")'
68+
69+
# Run R CMD check (without relying on r-lib/actions)
70+
# - name: Run R CMD check
71+
# env:
72+
# _R_CHECK_FORCE_SUGGESTS_: false
73+
# run: |
74+
# Rscript -e 'packageVersion("ggplot2")'
75+
# Rscript -e 'rcmdcheck::rcmdcheck(args="--no-manual", error_on="error")'
6176

6277
- name: Build site
6378
run: pkgdown::build_site_github_pages(new_process = FALSE, install = FALSE)

0 commit comments

Comments
 (0)