[{"data":1,"prerenderedAt":129},["ShallowReactive",2],{"blog-post-imagemagick-batch-resize-images":3,"recent-posts":67},{"id":4,"uid":5,"url":6,"type":7,"href":8,"tags":9,"first_publication_date":10,"last_publication_date":10,"slugs":11,"linked_documents":13,"lang":14,"alternate_languages":15,"data":16},"av7XDRIAAC0AmDyq","imagemagick-batch-resize-images",null,"blog_posts","https:\u002F\u002Fmarks-personal-website.cdn.prismic.io\u002Fapi\u002Fv2\u002Fdocuments\u002Fsearch?ref=awi2cRIAACwAhxgS&q=%5B%5B%3Ad+%3D+at%28document.id%2C+%22av7XDRIAAC0AmDyq%22%29+%5D%5D",[],"2026-11-25T22:45:23+0000",[12],"imagemagick-how-to-batch-resize-images",[],"en-us",[],{"title":17,"date":23,"description":24,"image":29,"content":39},[18],{"type":19,"text":20,"spans":21,"direction":22},"heading1","ImageMagick: How to Batch Resize Images",[],"ltr","2026-11-25",[25],{"type":26,"text":27,"spans":28,"direction":22},"heading2","Learn how to batch resize images using ImageMagick",[],{"dimensions":30,"alt":20,"copyright":6,"url":33,"id":34,"edit":35},{"width":31,"height":32},1280,720,"https:\u002F\u002Fimages.prismic.io\u002Fmarks-personal-website\u002FNGIU03qzUTFTu2hP_imagemagick-batch-resize-images.png?auto=format,compress","NGIU03qzUTFTu2hP",{"x":36,"y":36,"zoom":37,"background":38},0,1,"transparent",[40,44,48,51,54,57,60,64],{"type":41,"text":42,"spans":43,"direction":22},"paragraph","Before we start, make sure you have ImageMagick installed on your computer and your photos ready in a folder. If you don't have it yet, run this command:",[],{"type":45,"text":46,"spans":47,"direction":22},"preformatted","brew install imagemagick",[],{"type":41,"text":49,"spans":50,"direction":22},"First, open your terminal and navigate to the folder that has your photos. To resize all of your JPG files at once without touching the originals, run this command:",[],{"type":45,"text":52,"spans":53,"direction":22},"mkdir resized && magick mogrify -path resized -resize 800x600 *.jpg",[],{"type":41,"text":55,"spans":56,"direction":22},"The \u003Ccode>mkdir resized\u003C\u002Fcode> part creates a new folder for the copies. The \u003Ccode>-path resized\u003C\u002Fcode> option tells \u003Ccode>magick mogrify\u003C\u002Fcode> to save the resized photos there, and \u003Ccode>-resize 800x600\u003C\u002Fcode> fits every photo inside 800 by 600 pixels while keeping the aspect ratio. The \u003Ccode>*.jpg\u003C\u002Fcode> wildcard picks up every JPG file in the folder.",[],{"type":41,"text":58,"spans":59,"direction":22},"Don't worry if you don't see a success message, because ImageMagick stays quiet when it works. To make sure everything worked, run \u003Ccode>ls -lh resized\u003C\u002Fcode> to check the new file sizes, or open one of the photos.",[],{"type":61,"oembed":62},"embed",{"embed_url":63,"type":61},"",{"type":41,"text":65,"spans":66,"direction":22},"One more tip: if you only want to shrink photos that are bigger than your limit, put the size in quotes and add a greater than sign, like \u003Ccode>\"800x600>\"\u003C\u002Fcode>. You can also use \u003Ccode>50%\u003C\u002Fcode> to scale every photo by half.",[],{"results":68,"page":37,"results_per_page":127,"results_size":127,"total_results_size":128,"total_pages":37},[69,89,108],{"id":70,"uid":71,"url":6,"type":7,"href":72,"tags":73,"first_publication_date":74,"last_publication_date":74,"slugs":75,"linked_documents":77,"lang":14,"alternate_languages":78,"data":79},"awBNkxIAACkAFJ-q","hyperfine-multiple-parameters","https:\u002F\u002Fmarks-personal-website.cdn.prismic.io\u002Fapi\u002Fv2\u002Fdocuments\u002Fsearch?ref=awi2cRIAACwAhxgS&q=%5B%5B%3Ad+%3D+at%28document.id%2C+%22awBNkxIAACkAFJ-q%22%29+%5D%5D",[],"2026-11-26T22:45:05+0000",[76],"hyperfine-how-to-run-multiple-parameters",[],[],{"image":80,"title":86},{"dimensions":81,"alt":82,"copyright":6,"url":83,"id":84,"edit":85},{"width":31,"height":32},"Hyperfine: How to Run Multiple Parameters","https:\u002F\u002Fimages.prismic.io\u002Fmarks-personal-website\u002F_l5pwA96nzZYxC9L_hyperfine-multiple-parameters.png?auto=format,compress","_l5pwA96nzZYxC9L",{"x":36,"y":36,"zoom":37,"background":38},[87],{"type":19,"text":82,"spans":88,"direction":22},[],{"id":90,"uid":91,"url":6,"type":7,"href":92,"tags":93,"first_publication_date":74,"last_publication_date":74,"slugs":94,"linked_documents":96,"lang":14,"alternate_languages":97,"data":98},"awBNlhIAACoAFJ-_","bat-show-line-numbers","https:\u002F\u002Fmarks-personal-website.cdn.prismic.io\u002Fapi\u002Fv2\u002Fdocuments\u002Fsearch?ref=awi2cRIAACwAhxgS&q=%5B%5B%3Ad+%3D+at%28document.id%2C+%22awBNlhIAACoAFJ-_%22%29+%5D%5D",[],[95],"bat-how-to-show-line-numbers",[],[],{"image":99,"title":105},{"dimensions":100,"alt":101,"copyright":6,"url":102,"id":103,"edit":104},{"width":31,"height":32},"Bat: How to Show Line Numbers","https:\u002F\u002Fimages.prismic.io\u002Fmarks-personal-website\u002F9EACcMMdCc_YmGGd_bat-show-line-numbers.png?auto=format,compress","9EACcMMdCc_YmGGd",{"x":36,"y":36,"zoom":37,"background":38},[106],{"type":19,"text":101,"spans":107,"direction":22},[],{"id":109,"uid":110,"url":6,"type":7,"href":111,"tags":112,"first_publication_date":74,"last_publication_date":74,"slugs":113,"linked_documents":115,"lang":14,"alternate_languages":116,"data":117},"awBNlRIAAC4AFJ-5","bat-set-man-pager","https:\u002F\u002Fmarks-personal-website.cdn.prismic.io\u002Fapi\u002Fv2\u002Fdocuments\u002Fsearch?ref=awi2cRIAACwAhxgS&q=%5B%5B%3Ad+%3D+at%28document.id%2C+%22awBNlRIAAC4AFJ-5%22%29+%5D%5D",[],[114],"bat-how-to-set-bat-as-the-man-pager",[],[],{"image":118,"title":124},{"dimensions":119,"alt":120,"copyright":6,"url":121,"id":122,"edit":123},{"width":31,"height":32},"Bat: How to Set Bat as the Man Pager","https:\u002F\u002Fimages.prismic.io\u002Fmarks-personal-website\u002FTkD7gMTS-unoDHu6_bat-set-man-pager.png?auto=format,compress","TkD7gMTS-unoDHu6",{"x":36,"y":36,"zoom":37,"background":38},[125],{"type":19,"text":120,"spans":126,"direction":22},[],3,99,1795733125566]