Skip to content

Commit

Permalink
update main.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
simonliao98 committed Jan 2, 2025
1 parent 00feda7 commit 89e1a89
Showing 1 changed file with 12 additions and 20 deletions.
32 changes: 12 additions & 20 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,32 +10,24 @@ on:
workflow_dispatch:

jobs:
deploy:
name: Deploy to shinyapps

# allow skipping deployment for commits containing '[automated]' or '[no-deploy]' in the commit message
if: "!contains(github.event.head_commit.message, '[automated]') && !contains(github.event.head_commit.message, '[no-deploy]')"
shiny-deploy:
runs-on: ubuntu-latest
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
steps:
# Step 1: Check out the code from the repository
- uses: actions/checkout@v2

- name: Install system dependencies (libcurl)
run: |
sudo apt-get update
sudo apt-get install -y pkg-config libcurl4-openssl-dev
- uses: actions/checkout@v4

- uses: r-lib/actions/setup-pandoc@v2

- name: Set PKG_CONFIG_PATH
run: |
# Set PKG_CONFIG_PATH for libcurl to make sure pkg-config finds it
export PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig:$PKG_CONFIG_PATH
echo "PKG_CONFIG_PATH=$PKG_CONFIG_PATH" >> $GITHUB_ENV # Persist this for the rest of the workflow
echo "PKG_CONFIG_PATH: $PKG_CONFIG_PATH" # Print the value for debugging
- uses: r-lib/actions/setup-r@v2
with:
r-version: '4.1.1' # The R version to download (if necessary) and use.
use-public-rspm: true

- uses: r-lib/actions/setup-renv@v2

- name: Install rsconnect
run: install.packages("rsconnect")
shell: Rscript {0}

# Step 2: Install R packages
- name: install everything and deploy
Expand Down

0 comments on commit 89e1a89

Please sign in to comment.