D.1 More global options
|blogdown.hugo.dir||The directory of the Hugo executable|
|blogdown.method||html||The building method for R Markdown|
|blogdown.publishDir||The publish dir for local preview|
|blogdown.widgetsID||TRUE||Incremental IDs for HTML widgets?|
If you want to install Hugo to a custom path, you can set the global option
blogdown.hugo.dir to a directory to store the Hugo executable before you call
options(blogdown.hugo.dir = '~/Downloads/hugo_0.20.1/'). This may be useful for you to use a specific version of Hugo for a specific website,45 or store a copy of Hugo on a USB Flash drive along with your website.
blogdown.method is explained in Section D.9.
When your website project is under version control in the RStudio IDE, continuously previewing the site can be slow, if it contains hundreds of files or more. The default publish directory is
public/ under the project root directory, and whenever you make a change in the source that triggers a rebuild, RStudio will be busy tracking file changes in the
public/ directory. The delay before you see the website in the RStudio Viewer can be 10 seconds or even longer. That is why we provide the option
blogdown.publishDir. You may set a temporary publish directory to generate the website, and this directory should not be under the same RStudio project, e.g.,
options(blogdown.publishDir = '../public_site'), which means the website will be generated to the directory
public_site/ under the parent directory of the current project.
blogdown.widgetsID is only relevant if your website source is under version control and you have HTML widgets on the website. If this option is
TRUE (default), the random IDs of HTML widgets will be changed to incremental IDs in the HTML output, so these IDs are unlikely to change every time you recompile your website; otherwise, every time you will get different random IDs.