Returns the file type as a string.
Syntax
os.Path.type(
fname STRING)
RETURNING result STRING
- fname is the file name.
Usage
On UNIX™,
this method follows symbolic links. Use the os.Path.islink()
method to identify symbolic links.
The possible values returned
by this method are:
- file: the file is a regular file
- directory: the file is a directory
- socket: the file is a socket
- fifo: the file is a fifo
- block: the file is a block device
- char: the file is a character device