bashoneliners.com

Welcome to bashoneliners.com, a curated collection of practical and well-explained Bash one-liners, snippets, tips and tricks. We aim to make each published one-liner to be of high quality: useful, easy to read, follows best practices, with clear, detailed, accurate explanation. These one-liners should help you automate tasks, troubleshoot problems, whether it be in system administration, file management, networking or programming.

Search man pages and present a PDF

man -k . | awk '{ print $1, $2 }' | dmenu -i -p man | awk '{ print $2, $1 }' | tr -d '()' | xargs man -t | ps2pdf - - | zathura -

December 18, 2018Jab2870

Cut select pages from a pdf file and create a new file from those pages.

ps2pdf -dFirstPage=3 -dLastPage=10 input.pdf output.pdf

February 15, 2012Anon6y5E4Use