统计文件行数
find . -name ".js" |xargs cat|wc -l
拼接文件
find . -name ".js" |xargs cat > all_code.txt
cat -s all_code.txt | sed '/^[[:space:]]*$/d' > no_space_line.txt
cat -b no_space_line.txt > line_number.txt
统计文件行数
find . -name ".js" |xargs cat|wc -l
拼接文件
find . -name ".js" |xargs cat > all_code.txt
cat -s all_code.txt | sed '/^[[:space:]]*$/d' > no_space_line.txt
cat -b no_space_line.txt > line_number.txt
本文标题:Linux统计文件行数 拼接文件
本文链接:https://www.haomeiwen.com/subject/ixohuctx.html
网友评论