Skip to content

Commit

Permalink
Update R-CMD-check.yml
Browse files Browse the repository at this point in the history
Allow HTML doc generation on manual workflow dispatch
  • Loading branch information
brownag authored Mar 23, 2021
1 parent 3466277 commit 3761526
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions .github/workflows/R-CMD-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ on:
- master
schedule:
- cron: '0 0 * * 6' # At 00:00 on Saturday
workflow_dispatch:

name: R-CMD-check

Expand Down Expand Up @@ -100,7 +101,7 @@ jobs:
shell: Rscript {0}

- name: Render README
if: runner.os == 'Windows' && github.event_name == 'schedule'
if: runner.os == 'Windows' && (github.event_name == 'schedule' || github.event_name == 'workflow_dispatch')
run: |
install.packages(c("rmarkdown","devtools","pkgdown","aqp","soilDB","sharpshootR","dendextend","latticeExtra"))
remotes::install_github(c("ncss-tech/aqp","ncss-tech/sharpshootR"), dependencies = FALSE)
Expand All @@ -110,14 +111,14 @@ jobs:
shell: Rscript {0}

- name: Commit results
if: runner.os == 'Windows' && github.event_name == 'schedule'
if: runner.os == 'Windows' && (github.event_name == 'schedule' || github.event_name == 'workflow_dispatch')
run: |
git commit README.md -m 'Render README.Rmd' || echo "No changes to commit"
git add docs/\*
git commit -m 'Update Docs' || echo "No changes to commit"
- name: Push results
if: runner.os == 'Windows' && github.event_name == 'schedule'
if: runner.os == 'Windows' && (github.event_name == 'schedule' || github.event_name == 'workflow_dispatch')
run: |
git push origin HEAD:${{ env.BRANCH_NAME }} || echo "No changes to commit"
Expand Down

0 comments on commit 3761526

Please sign in to comment.