20251231 - instagram account #5
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #https://orchid00.github.io/actions_sandbox/websites-using-pkgdown-bookdown-and-blogdown.html#deploy-blogdown | |
| # To Do: | |
| # 1. Create a personal access token (PAT) labeled `EMAIL`: https://github.com/settings/tokens; save the value in LastPass | |
| # 2. Create a secret labeled `EMAIL` in the repo (Settings -> Security -> Secrets -> Actions), and copy the PAT for `EMAIL` into the secret labeled `EMAIL` | |
| on: | |
| push: | |
| branches: | |
| - main | |
| name: renderwiki | |
| jobs: | |
| rmarkdown: | |
| name: Render-Wiki | |
| runs-on: ubuntu-latest | |
| env: | |
| GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} | |
| steps: | |
| - name: Checkout Repository | |
| uses: actions/checkout@v4 # update | |
| - name: Setup R | |
| uses: r-lib/actions/setup-r@v2 # update | |
| - name: Session info | |
| run: Rscript -e 'sessionInfo()' | |
| - name: Setup pandoc | |
| uses: r-lib/actions/setup-pandoc@v2 # update | |
| - name: Install libcurl on Linux | |
| if: runner.os == 'Linux' | |
| run: sudo apt-get update -y && sudo apt-get install -y libcurl4-openssl-dev | |
| - name: Install package dependencies | |
| uses: r-lib/actions/setup-r-dependencies@v2 # update | |
| - name: Render wiki | |
| run: | | |
| Rscript -e 'rmarkdown::render_site()' | |
| git config --local user.name "$GITHUB_ACTOR" | |
| git config --local user.email "$GITHUB_ACTOR@users.noreply.github.com" | |
| git add . -f | |
| git commit -m 'Re-build wiki' || echo "No changes to commit" | |
| git push origin || echo "No changes to commit" |