file
Description:
determine file type
This call uses the standard file(1) command to determine the type or contents of the file.
This call will also transparently look inside various types of compressed file.
The exact command which runs is "file -zb path". Note in particular that the filename is not prepended to the output (the *-b* option).
The output depends on the output of the underlying file(1) command and it can change in future in ways beyond our control. In other words, the output is not guaranteed by the ABI.
See also: file(1), vfs_type, lstat, is_file, is_blockdev (etc), is_zero.
Parameters:
this |
A GuestfsSession object |
Returns:
the returned string, or NULL on error |