1
My intention is to print on the screen the number of pages of each PDF in a given directory. I even managed to do this through the following command:
find "$PWD" -iname "*.pdf" | xargs -i pdfinfo {} | grep Pages | sed 's/[^0-9]*//'
However, the answer to this command is only the number of pages of each PDF, one in each line.
My question is: how to format the above command response in order to print the name of each PDF file along with its number of pages, as follows:
nome_do_arquivo1.pdf : 230
nome_do_arquivo2.pdf : 123