thumbnail
重定向、命令行判断、管道、正则三剑客
# 特殊符号 | 引号类型 | 解析变量(`$var`) | 解析命令(`$(cmd)`) | 解析通配符(`*`) | 典型用途 | | ---------------------------- | -------------------- | -------------------- | ----------------- | --------…
thumbnail
Linux基础知识——Linux是什么及发展史
# day019-三剑客-正则表达式-习题 ## 过滤出/etc/passwd中包含root或nobody的行 ```shell grep -E 'root|nobody' /etc/passwd awk '/root|nobody/' /etc/passwd ``` ## 过滤出/etc/passwd中以root开头的行 ```shell gre…