Skip to content

Commit

Permalink
Combine Actions further
Browse files Browse the repository at this point in the history
  • Loading branch information
LukasWallrich committed May 27, 2024
1 parent 671fbbb commit e3d6b94
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 1 deletion.
File renamed without changes.
31 changes: 30 additions & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,40 @@ jobs:
- name: All Dependencies
run: ./run.sh install_all

- name: Create documentation
run: |
R -e "
install.packages(c('rcmdcheck', 'roxygen2', 'devtools'));
file.remove('NAMESPACE');
descr <- readLines('DESCRIPTION');
descr <- stringr::str_replace(descr, '^Date.*$', paste('Date:', Sys.Date()));
writeLines(descr, 'DESCRIPTION');
roxygen2::roxygenise();
try(devtools::build_manual())
"
- name: commit
run: |
git config --local user.email "[email protected]"
git config --local user.name "GitHub Actions"
git add -f man/\* NAMESPACE
git commit -m 'Documentation' || echo "No changes to commit"
git push origin || echo "No changes to commit"
- name: Deploy
run: |
R -e "
install.packages('rsconnect');
rsconnect::setAccountInfo(name=${{secrets.SHINY_LUKAS_ACCOUNT}}, token=${{secrets.SHINY_LUKAS_TOKEN}}, secret=${{secrets.SHINY_LUKAS_SECRET}});
rsconnect::deployApp(appName = 'CiteSource_latest', appDir = './inst/shiny-app/CiteSource')"
rsconnect::deployApp(appName = 'CiteSource_latest', appDir = './inst/shiny-app/CiteSource', forceUpdate = TRUE)"
- name: Deploy release version conditionally
if: github.event_name == 'release' && github.event.release.tag_name != '*test*'
run: |
R -e "
install.packages('rsconnect');
rsconnect::setAccountInfo(name=${{secrets.SHINY_LUKAS_ACCOUNT}}, token=${{secrets.SHINY_LUKAS_TOKEN}}, secret=${{secrets.SHINY_LUKAS_SECRET}});
rsconnect::deployApp(appName = 'CiteSource', appDir = './inst/shiny-app/CiteSource', forceUpdate = TRUE)"
- name: Create pkgdown
run: |
Expand All @@ -56,3 +84,4 @@ jobs:
branch: gh-pages
folder: docs

- uses: r-lib/actions/check-r-package@v2

0 comments on commit e3d6b94

Please sign in to comment.