'head'被信号13 Unix错误终止

时间:2014-12-03 05:01:56

标签: unix

尝试列出目录〜/ UnixCourse中所有文本文件的第一行。当我输入

代码:

find ~/UnixCourse -print -type f -name "*.txt" -exec head -1 {} \;

我收到此错误:

find: 'head' terminated by signal 13

我觉得我接近解决方案。任何建议将不胜感激。答案也必须是一线的

1 个答案:

答案 0 :(得分:0)

这适用于OS X 10.10和Debian:

find ~/UnixCourse -type f -name "*.txt" -print -exec head -1 {} \;
相关问题