-
Notifications
You must be signed in to change notification settings - Fork 0
/
bookdown_runfile.R
72 lines (49 loc) · 2.3 KB
/
bookdown_runfile.R
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
# Use these commands to actually render the handbook
# See format and content choices below
# test
################################################################################
# BS4 BOOKDOWN STYLE (WEBSITE VERSION) ##
#########################################
# WHOLE HANDBOOK
# for online viewing only - not available as a self-contained file
bookdown::render_book(
output_format = 'bookdown::bs4_book',
config_file = "_bookdown.yml")
# PREVIEW ONLY ONE OR SOME PAGES
# Edit which pages to include in "_small_bookdown.yml"
# To view, navigate to the "preview" folder and open "index.html"
bookdown::render_book(
output_format = 'bookdown::bs4_book',
config_file = "_small_bookdown.yml")
# To print only text with no code or figures, adjust this in the common.R script, also look at top of index.rmd
# print only text (not code)
#library(knitr)
#opts_chunk$set(list(echo = FALSE, eval = FALSE))
################################################################################
# WHOLE HANDBOOK WITHOUT TABS (long html)
# Available as a self-contained html file
# Ctrl+f Search functionality spans whole book
# !!! NOTE: this will output as "main.html" in the root folder. !!!
# Then you have to copy and re-name the file into the offline_long folder
bookdown::render_book(
output_format = 'bookdown::html_document2',
config_file = "_offline_long.yml")
################################################################################
# WHOLE HANDBOOK AS TABBED HTML
# for offline viewing - can be saved as a self-contained file
rmarkdown::render_site(
output_format = 'bookdown::html_document2')
# PREVIEW ONLY ONE OR SOME PAGES (tabbed html)
# For offline viewing - can be saved as a self-contained file
# Edit which pages are included in "_small_bookdown.yml"
# To view: navigate to the root project folder and open "_main.html"
bookdown::render_book(
output_format = 'bookdown::html_document2',
config_file = "_small_bookdown.yml")
################################################################################
# Render Long static pdf without tabs
bookdown::render_book(
output_format = 'bookdown::html_document2',
config_file = "_pdf_long.yml")
# render the contribution guide:
rmarkdown::render("contribution_guide_05-02-2021.Rmd", "html_document")