repo_check {repo} | R Documentation |
Checks that all indexed data are present in the repository root, that files are not corrupt and that no unindexed files are present.
repo_check()
Every time the object associated to an item is stored, an
MD5 checksum is saved to the repository index. check
will use those to verify that the object was not changed by
anything other than Repo itself.
Used for side effects.
## Repository creation
rp_path <- file.path(tempdir(), "example_repo")
rp <- repo_open(rp_path, TRUE)
rp_path <- file.path(tempdir(), "example_repo")
rp <- repo_open(rp_path, TRUE)
rp$put(0, "item1", "A sample item", "repo_check")
rp$check()
## wiping temporary repo
unlink(rp_path, TRUE)