LibreOffice has a nice command line interface which allows to convert documents into pdf.
For example to convert foo.odt document into foo.pdf use:
soffice -nologo -invisible-convert-to pdf foo.odt
Use the -outdir parameter to specify the output directory
soffice -nologo -invisible-convert-to pdf -outdir ./pdf foo.odt
Or to convert all documents from a directory use:
soffice -invisible -nologo -convert-to pdf *.odp
thumbs up for simplicity;
Be careful copying & pasting, those options start with double dashes but have been converted to em dashes by the blog software.
On Windows, there must be no running instances of OpenOffice/LibreOffice when this command is issued.
–headless is also easier and more effective than –nologo –invisible