get file name and extension

file_ext(file)

file_name(file)

Arguments

file

file path

Examples

file_name("./a.pdf")
#> [1] "a"
file_ext("./a.pdf")
#> [1] "pdf"