make | R Documentation |
Mock the Unix Make Utility
make(
name,
make_list,
force = FALSE,
recursive = force,
verbose = FALSE,
verbosity = 2,
dry_run = FALSE,
unconditionally = FALSE,
stop_on_warning = FALSE
)
name |
The name or alias of a make target. |
make_list |
The |
force |
Force the target to be build? See Details. |
recursive |
Force the target to be build recursively? See Details. |
verbose |
Be verbose? |
verbosity |
Give the level of verbosity. |
dry_run |
Run dry? Mock GNU |
unconditionally |
Force the target's code to be evaluated unconditionally to any prerequisites? See Details. |
stop_on_warning |
|
force, recursive
Forcing a target mocks adding .PHONY to a GNU Makefile
if you
set recursive to FALSE. If recursive is TRUE, then the whole make chain will
be forced.
unconditionally
Setting unconditionally
to TRUE
allows you to fool
make
similarily to using GNU make
's –touch option.
Invisibly
a character vector
containing the targets made during the current run.
str(make_list <- provide_make_list("minimal"))
# build all
withr::with_dir(tempdir(), print(make("all.Rout", make_list)))
# nothing to be done
withr::with_dir(tempdir(), print(make("all.Rout", make_list)))
# forcing all.Rout
withr::with_dir(tempdir(), print(make("all.Rout", make_list, force = TRUE,
recursive = FALSE)))
# forcing all.Rout recursively
withr::with_dir(tempdir(), print(make("all.Rout", make_list, force = TRUE)))
# show files
dir(tempdir(), pattern = ".*\\.Rout")
# dry run
file.remove(dir(tempdir(), pattern = ".*\\.Rout", full.names = TRUE))
withr::with_dir(tempdir(), print(make("all.Rout", make_list,
dry_run = TRUE)))
dir(tempdir(), pattern = ".*\\.Rout")
# make unconditionally
dir(tempdir(), pattern = ".*\\.Rout")
withr::with_dir(tempdir(), print(make("all.Rout", make_list,
unconditionally = TRUE)))
dir(tempdir(), pattern = ".*\\.Rout")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.