list_file_paths: list_file_paths

Description Usage Arguments

View source: R/list_file_paths.R

Description

a wrapper for the base function list.files(). Instead of returning just the list of the file names, it returns the full path to those files as a named list.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
list_file_paths(
  path,
  pattern = NULL,
  all.files = FALSE,
  full.names = FALSE,
  recursive = FALSE,
  ignore.case = FALSE,
  include.dirs = FALSE,
  no.. = FALSE,
  return_absolute = FALSE
)

Arguments

path

a character vector of full path names; the default corresponds to the working directory, getwd(). Tilde expansion (see path.expand) is performed. Missing values will be ignored.

pattern

an optional regular expression. Only file names which match the regular expression will be returned.

all.files

a logical value. If FALSE, only the names of visible files are returned. If TRUE, all file names will be returned.

full.names

a logical value. If TRUE, the directory path is prepended to the file names to give a relative file path. If FALSE, the file names (rather than paths) are returned.

recursive

logical. Should the listing recurse into directories?

ignore.case

logical. Should pattern-matching be case-insensitive?

include.dirs

logical. Should subdirectory names be included in recursive listings? (They always are in non-recursive ones).

no..

logical. Should both "." and ".." be excluded also from non-recursive listings?

return_absolute

logical. Should absolute file paths be returned. If false, only relative file paths are returned.


lina2497/alextools documentation built on June 7, 2020, 10:29 a.m.