【发布时间】:2016-08-01 12:06:25
【问题描述】:
我正在使用 pdfgrep 在存储在目录中的多个 pdf 中搜索名称并将结果存储在文件中:
pdfgrep -R 'My string' > ../output-file
它打印以下输出:
./file1.pdf: 91 My String Just_another_string 75 53 49 30 57 48 74 69
./file2.pdf: 8 My String Just_another_string 40
./file3.pdf: 92 My String Just_another_string 64 62 76 50 76 88 80 148
我在输出的每一列之间的每一行中都得到了很多不必要的空格。我想重新格式化输出,使这些多个空格减少到每列之间只有一个空格。
有什么办法可以做到吗?提前致谢。
【问题讨论】:
标签: linux pdf grep formatting output