% To receive output for a database update, use the "-B" flag. % See % Note: this output has been filtered. % % The RIPE Database is subject to Terms and Conditions. % This is the RIPE Database query service. These functions above will be used in my pdf2searchablepdf project here.The pdfinfo technique in Ocaso's answer below is also very fast-the same as the pdftoppm one. Testing them with the time command in front shows that the strings one is extremely slow, taking ~0.200 sec on a 142 pg pdf, whereas the pdftoppm one is very fast, taking ~0.020 sec or less on the same pdf. # SUPER SLOW! Putting `time` just in front of the `strings` cmd shows it takes ~0.200 sec on a 142 # num_pgs="$(getNumPgsInPdf "path/to/mypdf.pdf")" # Usage (works on ALL PDFs-whether password-protected or not!): #PDFINFO CMSSDST PDF#Here are a couple wrapper functions to test these: # get the total number of pages in a PDF technique 1. That's it! Wrapper functions and speed testing part with this regular expression ( (*)\.$), then I pipe that to grep again with this regular expression ( *) to find just the number, which is 142 in this case. So, I pipe that stderr msg to stdout with 2>
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |