You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
914 B

% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/get-content-type.R
\title{Discover MIME type of a file based on contents}
\item{path}{path to a file}
character vector
There are a limited number of header "magic" bytes checked directly by
this function but cover quite a bit of ground. After that, \code{\link[=guess_content_type]{guess_content_type()}} is called which uses
file extension-to-MIME mappings. File an issue or PR if more magic-byte-level
comparisons are required/desired. If no match is found, \code{???} is returned.
Initial in-R header mapping logic borrowed from \code{} from
get_content_type(system.file("extdat", "test.pdf", package="wand"))