`full_path_chain` represents another approach to creating chainable paths In contrast to `path_chain`, this functon creates just a list with nested list with full paths as a leaves.

full_path_chain(path = ".", root.name = ".", naming = basename)

Arguments

path

root path

root.name

naming convention for root directory

naming

naming function

Value

list of lists and character objects

Examples

tmp <- create_temp_dir("files") create_sample_dir(tmp, override = TRUE)
#> [1] TRUE
fs::dir_tree(tmp)
#> /tmp/Rtmp4l1UVj/files #> ├── data #> │ ├── example1.RData #> │ ├── example2.RData #> │ └── persons.csv #> └── docs #> └── schema.txt
chainable.path <- full_path_chain(tmp) chainable.path
#> $. #> [1] "/tmp/Rtmp4l1UVj/files" #> #> $data #> $data$. #> [1] "/tmp/Rtmp4l1UVj/files/data" #> #> $data$example1.RData #> [1] "/tmp/Rtmp4l1UVj/files/data/example1.RData" #> #> $data$example2.RData #> [1] "/tmp/Rtmp4l1UVj/files/data/example2.RData" #> #> $data$persons.csv #> [1] "/tmp/Rtmp4l1UVj/files/data/persons.csv" #> #> #> $docs #> $docs$. #> [1] "/tmp/Rtmp4l1UVj/files/docs" #> #> $docs$schema.txt #> [1] "/tmp/Rtmp4l1UVj/files/docs/schema.txt" #> #>