whereis.sh
来自「操作系统源代码」· Shell 代码 · 共 23 行
SH
23 行
: List all system directories containing the argument: Author: Terrence W. Holmif test $# -ne 1; then echo "Usage: whereis name" exit 1fipath="/bin /lib /etc\ /usr/bin /usr/lib\ /usr/include /usr/include/sys"for dir in $path; do for file in $dir/$1 $dir/$1.*; do if test -f $file; then echo $file elif test -d $file; then echo $file/ fi done doneexit 0
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?