orderly_commit {orderly} | R Documentation |
Commit a generated report
Description
Commit a generated report, moving it from the draft/
directory to archive/
and updating the orderly index. Once
committed, reports should not be deleted.
Usage
orderly_commit(id, name = NULL, root = NULL, locate = TRUE, timeout = 10)
Arguments
id |
The identifier of the report |
name |
The name of the report - this can be omitted and the
name will be determined from the |
root |
The path to an orderly root directory, or |
locate |
Logical, indicating if the configuration should be
searched for. If |
timeout |
Time in seconds to wait for db to be available. In
parallel the database may become locked so we can choose to wait
for |
Value
The path to the newly committed report
Examples
# In a new example orderly, run a report
path <- orderly::orderly_example("minimal")
id <- orderly::orderly_run("example", root = path)
# To commit it, all we need is the report id
orderly::orderly_commit(id, root = path)
# The report is now committed, and as such could be used as a
# dependency in another report and is not subject to deletion by
# orderly::orderly_cleanup
orderly::orderly_list_archive(root = path)