Bash file 命令详解

file命令用来某个文件的类型。

$ file index.html
 index.html: HTML document, ASCII text

file 工具可以对所给的文件一行简短的介绍,它用文件后缀、头部信息和一些其他的线索来判断文件。你在检查一堆你不熟悉的文件时使用 find 非常方便:

$ find -exec file {} \;
.:            directory
./hanoi:      Perl script, ASCII text executable
./.hanoi.swp: Vim swap file, version 7.3
./factorial:  Perl script, ASCII text executable
./bits.c:     C source, ASCII text
./bits:       ELF 32-bit LSB executable, Intel 80386, version ...

教程来源于Github,感谢大佬的无私奉献,致敬!

技术教程推荐

如何设计一个秒杀系统 -〔许令波〕

OpenResty从入门到实战 -〔温铭〕

说透敏捷 -〔宋宁〕

Vim 实用技巧必知必会 -〔吴咏炜〕

To B市场品牌实战课 -〔曹林〕

MySQL 必知必会 -〔朱晓峰〕

技术面试官识人手册 -〔熊燚(四火)〕

业务开发算法50讲 -〔黄清昊〕

大型Android系统重构实战 -〔黄俊彬〕