Skip to contents

Check if directory is a webrarian collection

Usage

is_collection(path = ".")

Arguments

path

Path to check

Value

TRUE if the directory contains a _webrarian.yml file.

Examples

is_collection(collection_example("basic"))
#> ✔ Copied the "basic" example to /tmp/RtmpQU25pJ/webrarian-basic-206b59e9bce4
#> /tmp/RtmpQU25pJ/webrarian-basic-206b59e9bce4/_webrarian.yml 
#>                                                        TRUE 

is_collection(tempdir())
#> /tmp/RtmpQU25pJ/_webrarian.yml 
#>                          FALSE