简体   繁体   English

Sejda合并CSV文件列表名称中的PDF

[英]Sejda merging PDFs from CSV filelist names

I recently installed sedja-console for merging pdf files from command line. 我最近安装了sedja-console用于从命令行合并pdf文件。

The names of the input pdf files are in a CSV file named filelist-inputs.csv like this: 输入的pdf文件的名称位于名为filelist-inputs.csv的CSV文件中,如下所示:

./Temp/source/046032.pdf,./Temp/source/048155.pdf
./Temp/source/049278.pdf,./Temp/source/050818.pdf,./Temp/source/052962.pdf
./Temp/source/052962.pdf,./Temp/source/054117.pdf

I need one output pdf file for the first line of the CSV filelist names, other output pdf file for the second line of the second line, other output for the third line, and so... 我需要一个输出pdf文件用于CSV文件列表名称的第一行,其他输出pdf文件用于第二行的第二行,其他输出用于第三行,依此类推...

I tried a command line like this: 我试过这样的命令行:

~$ sejda-console merge -l filelist-inputs.csv -o ./Temp/target/merged[FILENUMBER####].pdf

But it only creates a unique file named literally merged[FILENUMBER####].pdf , when I want 3 files: 但是,当我需要3个文件时,它仅创建一个名为literally merged[FILENUMBER####].pdf的唯一文件:

merged0001.pdf
merged0002.pdf
merged0003.pdf

I've simplified the problem, because I need to merge more than 3500 pdf files in 700 output files. 我已经简化了问题,因为我需要在700个输出文件中合并3500个以上的pdf文件。

Sejda takes all the values in the CSV and generates a single merged PDF, there isn't any option or setting in Sejda to achieve what you asked, you will need some scripting to loop through the CSV lines, create a CSV per line and feed it to Sejda. Sejda会采用CSV中的所有值并生成一个合并的PDF,而Sejda中没有任何选项或设置可以实现您所要求的功能,您将需要一些脚本来循环遍历CSV行,为每行创建CSV并供稿交给世达

The output file name merged[FILENUMBER####].pdf is literally used because the PDF merge task generates one output file and it expects an explicit output file name. 实际使用输出文件名称merged[FILENUMBER####].pdf因为PDF合并任务会生成一个输出文件,并且期望使用显式的输出文件名。 Prefixes like [CURRENTPAGE] or [FILENUMBER] are valid when used as -p argument in tasks generating multiple output PDF files (split tasks etc). 前缀[CURRENTPAGE][FILENUMBER]在生成多个输出PDF文件的任务(拆分任务等)中用作-p参数时有效。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM