Skip to content

Commit c1b3791

Browse files
committed
GHA rhub workflow: use .Rprofile to set options(repos)
1 parent 702358e commit c1b3791

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

.github/workflows/rhub.yaml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,10 @@ jobs:
5252

5353
steps:
5454
- uses: r-hub/actions/checkout@v1
55+
- name: Add additional r-universe repository
56+
run: |
57+
# Add additional r-universe repository
58+
echo 'options(repos = c(getOption("repos"), "https://geocompr.r-universe.dev"))' >> ~/.Rprofile
5559
- uses: r-hub/actions/platform-info@v1
5660
with:
5761
token: ${{ secrets.RHUB_TOKEN }}
@@ -84,8 +88,7 @@ jobs:
8488
- name: Add additional r-universe repository
8589
run: |
8690
# Add additional r-universe repository
87-
options(repos = c(getOption("repos"), "https://geocompr.r-universe.dev"))
88-
shell: Rscript {0}
91+
echo 'options(repos = c(getOption("repos"), "https://geocompr.r-universe.dev"))' >> ~/.Rprofile
8992
- uses: r-hub/actions/platform-info@v1
9093
with:
9194
token: ${{ secrets.RHUB_TOKEN }}

0 commit comments

Comments
 (0)