什么是unix上的常规文件

Vij*_*jay 12 unix file manpage

我看到了手册页test.

提到下面的地方.

-e  pathname
    True if pathname resolves to a file that exists. False if pathname cannot be resolved.
-f  pathname
    True if pathname resolves to a file that exists and is a regular file. False if pathname cannot be resolved, or if pathname resolves to a file that exists but is not a regular file.
Run Code Online (Sandbox Code Playgroud)

如果pathname解析为存在的文件并且是常规文件,则-f标志表示 True 可以告诉任何人什么是常规文件以及什么不是常规文件.

Cos*_*atu 9

非常规文件是设备,管道,套接字...... [ -f /dev/tty0 ]例如,尝试.符号链接也是非正规,但他们决心通过test -f.


str*_*mqm 9

它们是文本或二进制数据,称为"常规文件",以区别于其他类型,如目录,符号链接,套接字等.

看看http://en.wikipedia.org/wiki/Unix_file_types