ice*_*ead 6 unix bash grep locate
我正在尝试使用grep自动在用户的bin文件夹中找到bibtex程序.
问题是,它经常返回名为bibtex的目录,这意味着脚本无法自动运行该命令.
如何强制grep(或者确实是locate命令)自动忽略目录?
编辑:当前命令是: locate bibtex | grep "/bibtex$" -d skip | head -n1
locate bibtex | grep "/bibtex$" -d skip | head -n1
Ste*_*ton 12
该find命令?
find
find /bin -name bibtex -type f
查找"f"类型的文件名"bibtex",这是一个常规文件.
归档时间:
13 年,6 月 前
查看次数:
3367 次
最近记录: