orderly (version 1.0.4)

orderly_run_info: Information on current orderly run

Description

This function allows inspection of some of orderly's metadata during an orderly run. The format returned is internal to orderly and subject to change. It is designed to be used within report code. To use in conjunction with orderly_test_start, you must pass in the path to the report in question.

Usage

orderly_run_info(path = NULL)

Arguments

path

Path to the report currently being run. This should be left as NULL when running a report, and the path to the report being run should be used when using orderly_test_start

Value

A list of metadata about the current report

Examples

Run this code
# NOT RUN {
path <- orderly::orderly_example("demo")

# This example uses orderly_run_info within its script, saving the
# output to "output.rds"
readLines(file.path(path, "src", "use_dependency", "script.R"))

# Run the dependency:
id <- orderly::orderly_run("other", list(nmin = 0), root = path)
orderly::orderly_commit(id, root = path)

# Then the report
id <- orderly::orderly_run("use_dependency", root = path)

# This is the contents:
readRDS(file.path(path, "draft", "use_dependency", id, "info.rds"))
# }

Run the code above in your browser using DataLab