Skip to content

Commit

Permalink
Restore student guide build
Browse files Browse the repository at this point in the history
  • Loading branch information
avahoffman committed Jan 15, 2025
1 parent ef7ca82 commit ddae331
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,23 @@ jobs:
if: ${{needs.yaml-check.outputs.toggle_website == 'quarto' }}
run: Rscript -e "quarto::quarto_render('.')"

# Render a student guide if specified. This is a bit clunky because
# Bookdown does not work well if the files aren't named as such in the
# root directory
- name: Run student guide render
if: ${{needs.yaml-check.outputs.toggle_student_guide == 'yes'}}
id: student_guide
run: |
mkdir tmp1
mv _bookdown.yml _output.yml tmp1
mv student-guide/_bookdown.yml student-guide/_output.yml .
Rscript -e "bookdown::render_book('index.Rmd', output_format = 'all')"
mv _bookdown.yml _output.yml student-guide
mv tmp1/_bookdown.yml tmp1/_output.yml .
rm -r tmp1
git add student-guide/*
git commit -m 'Create student guide' || echo "No changes to commit"
# This checks on the steps before it and makes sure that they completed.
# If the renders didn't complete we don't want to commit the file changes
- name: Check on Rmd render steps
Expand Down

0 comments on commit ddae331

Please sign in to comment.