pdftotext -layout input.pdf output.txt
Let us know how you use command-line tools to handle PDFs in the comments below! xpdf tools
pdftotext input.pdf output.txt
sudo dnf install xpdf