[{"data":1,"prerenderedAt":117},["ShallowReactive",2],{"blog-post-bat-set-man-pager":3,"recent-posts":73},{"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},"awBNlRIAAC4AFJ-5","bat-set-man-pager",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+%22awBNlRIAAC4AFJ-5%22%29+%5D%5D",[],"2026-11-26T22:45:05+0000",[12],"bat-how-to-set-bat-as-the-man-pager",[],"en-us",[],{"title":17,"date":23,"description":24,"image":29,"content":39},[18],{"type":19,"text":20,"spans":21,"direction":22},"heading1","Bat: How to Set Bat as the Man Pager",[],"ltr","2026-11-26",[25],{"type":26,"text":27,"spans":28,"direction":22},"heading2","Learn how to set bat as the man pager for colorful man pages",[],{"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\u002FTkD7gMTS-unoDHu6_bat-set-man-pager.png?auto=format,compress","TkD7gMTS-unoDHu6",{"x":36,"y":36,"zoom":37,"background":38},0,1,"transparent",[40,44,48,51,54,57,60,63,66,70],{"type":41,"text":42,"spans":43,"direction":22},"paragraph","Before we start, make sure you have bat installed on your computer. If you don't have it yet, run this command:",[],{"type":45,"text":46,"spans":47,"direction":22},"preformatted","brew install bat",[],{"type":41,"text":49,"spans":50,"direction":22},"By default, man shows pages in a pager called less, and everything is one colour. To make bat the pager, add this line to your shell config. I'm using zsh, so that's \u003Ccode>~\u002F.zshrc\u003C\u002Fcode>:",[],{"type":45,"text":52,"spans":53,"direction":22},"echo 'export MANPAGER=\"bat -plman\"' >> ~\u002F.zshrc",[],{"type":41,"text":55,"spans":56,"direction":22},"If you use bash, add the same line to \u003Ccode>~\u002F.bashrc\u003C\u002Fcode> instead. The \u003Ccode>-p\u003C\u002Fcode> flag turns off the borders and line numbers, and \u003Ccode>-l man\u003C\u002Fcode> tells bat the text is a man page, which gives you the syntax colours.",[],{"type":41,"text":58,"spans":59,"direction":22},"Now reload your config:",[],{"type":45,"text":61,"spans":62,"direction":22},"source ~\u002F.zshrc",[],{"type":41,"text":64,"spans":65,"direction":22},"To make sure it worked, open any man page, for example \u003Ccode>man ls\u003C\u002Fcode>. The headings, command names and options are now highlighted, and you still press \u003Ccode>q\u003C\u002Fcode> to quit.",[],{"type":67,"oembed":68},"embed",{"embed_url":69,"type":67},"",{"type":41,"text":71,"spans":72,"direction":22},"If you ever want to go back, just delete that line from your config file and open a new terminal.",[],{"results":74,"page":37,"results_per_page":115,"results_size":115,"total_results_size":116,"total_pages":37},[75,94,113],{"id":76,"uid":77,"url":6,"type":7,"href":78,"tags":79,"first_publication_date":10,"last_publication_date":10,"slugs":80,"linked_documents":82,"lang":14,"alternate_languages":83,"data":84},"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",[],[81],"hyperfine-how-to-run-multiple-parameters",[],[],{"image":85,"title":91},{"dimensions":86,"alt":87,"copyright":6,"url":88,"id":89,"edit":90},{"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},[92],{"type":19,"text":87,"spans":93,"direction":22},[],{"id":95,"uid":96,"url":6,"type":7,"href":97,"tags":98,"first_publication_date":10,"last_publication_date":10,"slugs":99,"linked_documents":101,"lang":14,"alternate_languages":102,"data":103},"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",[],[100],"bat-how-to-show-line-numbers",[],[],{"image":104,"title":110},{"dimensions":105,"alt":106,"copyright":6,"url":107,"id":108,"edit":109},{"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},[111],{"type":19,"text":106,"spans":112,"direction":22},[],{"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":114},{"image":29,"title":17},3,99,1795733125375]