{"id":10651,"date":"2023-07-22T21:33:40","date_gmt":"2023-07-22T19:33:40","guid":{"rendered":"https:\/\/monodes.com\/predaelli\/?p=10651"},"modified":"2023-12-16T14:06:07","modified_gmt":"2023-12-16T13:06:07","slug":"converting-a-multi-page-pdf-to-multiple-pages-using-a-single-command","status":"publish","type":"post","link":"https:\/\/monodes.com\/predaelli\/2023\/07\/22\/converting-a-multi-page-pdf-to-multiple-pages-using-a-single-command\/","title":{"rendered":"Converting a multi page pdf to multiple pages using a single command"},"content":{"rendered":"\n<p><a href=\"https:\/\/stackoverflow.com\/questions\/17025515\/converting-a-multi-page-pdf-to-multiple-pages-using-a-single-command\">imagemagick &#8211; Converting a multi page pdf to multiple pages using a single command &#8211; Stack Overflow<\/a><\/p>\n\n\n\n<p>It&#8217;s as simple as<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code class=\"\" data-line=\"\">convert x.pdf x-%04d.jpg\n<\/code><\/pre>\n\n\n\n<p>Where <code class=\"\" data-line=\"\">4<\/code> means 4 digits will be show on the page count. You can change jpg to webp or whatever and ImageMagick understand it.<\/p>\n\n\n\n<p>The codes used are the same of the <a href=\"https:\/\/www.man7.org\/linux\/man-pages\/man3\/printf.3.html\"><kbd>printf<\/kbd> function<\/a> of standard library of the C programming language<\/p>\n","protected":false},"excerpt":{"rendered":"<p class=\"excerpt\">imagemagick &#8211; Converting a multi page pdf to multiple pages using a single command &#8211; Stack Overflow It&#8217;s as simple as Where 4 means 4 digits will be show on the page count. You can change jpg to webp or whatever and ImageMagick understand it. The codes used are the same of the printf function&hellip;<\/p>\n<p class=\"more-link-p\"><a class=\"more-link\" href=\"https:\/\/monodes.com\/predaelli\/2023\/07\/22\/converting-a-multi-page-pdf-to-multiple-pages-using-a-single-command\/\">Read more &rarr;<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"inline_featured_image":false,"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"activitypub_content_warning":"","activitypub_content_visibility":"","activitypub_max_image_attachments":4,"activitypub_interaction_policy_quote":"anyone","activitypub_status":"","footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[278],"tags":[],"class_list":["post-10651","post","type-post","status-publish","format-standard","hentry","category-tricks"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p6daft-2LN","jetpack-related-posts":[{"id":12887,"url":"https:\/\/monodes.com\/predaelli\/2025\/03\/04\/imagemagick-reduce-size-of-pdf\/","url_meta":{"origin":10651,"position":0},"title":"imagemagick reduce size of pdf","author":"Paolo Redaelli","date":"2025-03-04","format":false,"excerpt":"convert -density 150 -quality 60 -compress jpeg Test.pdf Test-150-060-jpeg.pdf Source: imagemagick reduce size of pdf - Stack Overflow","rel":"","context":"In &quot;Tricks&quot;","block_context":{"text":"Tricks","link":"https:\/\/monodes.com\/predaelli\/category\/documentations\/tricks\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":7334,"url":"https:\/\/monodes.com\/predaelli\/2020\/06\/11\/imagemagick-remove-black-borders\/","url_meta":{"origin":10651,"position":1},"title":"ImageMagick &#8211; Remove black borders","author":"Paolo Redaelli","date":"2020-06-11","format":false,"excerpt":"It is as simple as: magick mogrify -fuzz 4% -define trim:percent-background=0% -trim +repage -format jpg img.jpg Source: Stack Overflow","rel":"","context":"In &quot;Documentations&quot;","block_context":{"text":"Documentations","link":"https:\/\/monodes.com\/predaelli\/category\/documentations\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":1620,"url":"https:\/\/monodes.com\/predaelli\/2016\/06\/02\/jquery-image-manipulation\/","url_meta":{"origin":10651,"position":2},"title":"Jquery Image manipulation","author":"Paolo Redaelli","date":"2016-06-02","format":"link","excerpt":"Jqmagick : ImageMagick & Jquery Image manipulation","rel":"","context":"In &quot;Javascript&quot;","block_context":{"text":"Javascript","link":"https:\/\/monodes.com\/predaelli\/category\/javascript\/"},"img":{"alt_text":"jqmagick","src":"https:\/\/i0.wp.com\/monodes.com\/predaelli\/wp-content\/uploads\/sites\/4\/2016\/06\/jqmagick-300x262-1.png?resize=350%2C200","width":350,"height":200},"classes":[]},{"id":13797,"url":"https:\/\/monodes.com\/predaelli\/2025\/07\/20\/13797\/","url_meta":{"origin":10651,"position":3},"title":"I visited Terence blog to\u2026","author":"Paolo Redaelli","date":"2025-07-20","format":false,"excerpt":"I visited Terence blog to read about some Easy ways to add watermarks to images and videos in Linux but I found a very nice and clean to take inspiration from! Mostly notes to myself :-) Here is a quick way to add watermarks to photos and videos. All Linux\u2026","rel":"","context":"In &quot;Senza categoria&quot;","block_context":{"text":"Senza categoria","link":"https:\/\/monodes.com\/predaelli\/category\/senza-categoria\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/shkspr.mobi\/blog\/wp-content\/litespeed\/avatar\/af6a5dd8373bf52386c67599d3a74158.jpg?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":6834,"url":"https:\/\/monodes.com\/predaelli\/2020\/03\/04\/useful-ffmpeg-commands-for-working-with-audio-and-video-files-digital-inspiration\/","url_meta":{"origin":10651,"position":4},"title":"Useful FFmpeg Commands for Working with Audio and Video Files &#8211; Digital Inspiration","author":"Paolo Redaelli","date":"2020-03-04","format":"link","excerpt":"Useful FFmpeg Commands for Working with Audio and Video Files - Digital Inspiration Useful FFmpeg Commands FFmpeg supports all popular audio and video formats. Or you can running the command .\/ffmpeg -formats to get a list of every format that is supported by your FFmpeg installation. If you are just\u2026","rel":"","context":"In &quot;Documentations&quot;","block_context":{"text":"Documentations","link":"https:\/\/monodes.com\/predaelli\/category\/documentations\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":11243,"url":"https:\/\/monodes.com\/predaelli\/2024\/01\/19\/pssh-run-commands-on-multiple-remote-linux-systems\/","url_meta":{"origin":10651,"position":5},"title":"PSSH &#8211; Run Commands on Multiple Remote Linux Systems","author":"Paolo Redaelli","date":"2024-01-19","format":"link","excerpt":"\u00a0PSSH is a small Python-based program, which allows you to execute commands on multiple Linux remote servers in parallel at the same time using the single shell. Source:- Run Commands on Multiple Remote Linux Systems","rel":"","context":"In &quot;Tricks&quot;","block_context":{"text":"Tricks","link":"https:\/\/monodes.com\/predaelli\/category\/documentations\/tricks\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]}],"jetpack_likes_enabled":true,"_links":{"self":[{"href":"https:\/\/monodes.com\/predaelli\/wp-json\/wp\/v2\/posts\/10651","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/monodes.com\/predaelli\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/monodes.com\/predaelli\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/monodes.com\/predaelli\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/monodes.com\/predaelli\/wp-json\/wp\/v2\/comments?post=10651"}],"version-history":[{"count":0,"href":"https:\/\/monodes.com\/predaelli\/wp-json\/wp\/v2\/posts\/10651\/revisions"}],"wp:attachment":[{"href":"https:\/\/monodes.com\/predaelli\/wp-json\/wp\/v2\/media?parent=10651"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/monodes.com\/predaelli\/wp-json\/wp\/v2\/categories?post=10651"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/monodes.com\/predaelli\/wp-json\/wp\/v2\/tags?post=10651"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}