Closed bbest closed 3 years ago
hey @bbest - issue fixed. The problem was with the capitalization of the extension of kelp-forest-biogenic-invertebrates.rmd. All other R Markdown files in that folder have the extension ".Rmd". This one has the extension ".rmd". The function nms4r::generate_html_4_rmd(), on one line, is case sensitive with the extension. I fixed that one line, so that the function is no longer sensitive to capitalization in the extension.
Line 58 in the function goes from:
target_html <- gsub("Rmd", "html", target_rmd)
to:
target_html <- gsub("Rmd", "html", target_rmd, ignore.case = TRUE)
I updated the _site.yml file in the modals folder to include Ganalytics.html. I then reran all of the modal R Markdown files using nms4r::render_all_rmd(render_all=T)
and it all worked fine.
However, I was unable to push my changes up to the cinms repo, as RStudio kept crashing if I attempted to push more than one file at a time. This seems to be some particular problem with the cinms repo and Windows, as I am not having this issue with other repos. I tried several fixes to solve the issue, but no luck.
So, I think that you will need to update the modal windows, as I am unable to do so. I did update the _site.yml in the modals folder of the repo to include Ganalytics. You'll just need to pull that and then you can run nms4r::render_all_rmd(render_all=T)
. Hopefully you won't have the same issue as I did when committing your changes.
@bbest - success! I used github desktop and was able to push my updated files for the modal folder. So, no need for you to run render_all_rmd
Hi Jai,
Thanks for explanation in https://github.com/marinebon/cinms/commit/da5a41dc245ecfffe123b156353869adac66f309#commitcomment-49328591 to my message "+ render_site.R after deleted by @superjai (why?!)":
I'm trying to setup Google Analytics for cinms #77. I updated the README.md to reflect this new way of rendering the pages:
Looks like it's mostly working, but I ran into a snag running
render_all_rmd(render_all = T)
withmodals/kelp-forest-biogenic-invertebrates.Rmd
. Could you please look into getting this to work?Thanks, Ben
PS Here's the log output for the problematic file...