Skip to content

Commit

Permalink
Merge pull request #359 from insightsengineering/fix-gha-cache
Browse files Browse the repository at this point in the history
disable refresh for documentation checks
  • Loading branch information
gowerc authored May 18, 2022
2 parents 4fd87b7 + d5e14f4 commit 25fd7f2
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
11 changes: 9 additions & 2 deletions .github/actions/build-src/action.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@

name: 'Build src'
description: 'Build src!'
inputs:
refresh:
description: 'Should the R/stanmodels.R file be refreshed'
default: true
runs:
using: "composite"
steps:
Expand All @@ -21,9 +25,12 @@ runs:
# but as we are using cached models we are preventing compilation
# and thus need to manually refresh the file
- name: Refresh rstantools config files
shell: bash
run: |
rstantools::rstan_config()
shell: Rscript {0}
echo "inputs.refresh = ${{ inputs.refresh }}"
if ${{ inputs.refresh }} ; then
Rscript -e "rstantools::rstan_config()"
fi
- name: Cache Compiled Stan Code
id: cache-pkgs
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/on_push.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ jobs:

- name: Build src
uses: ./.github/actions/build-src
with:
refresh: false

- name: Document Code
run: |
Expand Down

0 comments on commit 25fd7f2

Please sign in to comment.