jhudsl / OTTR_Template

OTTR for making courses! This is a template repo that helps people write 1 course but publish it in three places
https://www.ottrproject.org/
Creative Commons Attribution 4.0 International
17 stars 13 forks source link

Bookdown doesn't seem to clean out old files? #111

Closed cansavvy closed 2 years ago

cansavvy commented 3 years ago

As re-renders of bookdown happen it looks like it doesn't actually delete the older versions of the files from docs/. Granted those files hanging around don't hurt anything and aren't used by the final render of bookdown, but it does get messy after awhile.

Perhaps we can either find a bookdown.yml setting that does clean this out OR we can just do it informally by adding a delete the docs/ folder step before re-rendering with GHA.

cansavvy commented 3 years ago

I would have thought this would be doing the trick: https://github.com/jhudsl/DaSL_Course_Template_Bookdown/blob/ca63442da64148e0dc414e8df9cbde59e126ed18/_bookdown.yml#L11

But on other repos I'm not seeing it clear out old files: https://github.com/jhudsl/ITCR_Documentation_and_Usability/tree/main/docs

cansavvy commented 2 years ago

This is a problem and its overdue that I fix it. I think easiest approach is to have render-bookdown.yml delete the docs/* folder completely before running. Or is that too dangerous?

cansavvy commented 2 years ago

Testing this idea here: https://github.com/jhudsl/Reproducibility_in_Cancer_Informatics/pull/46