August 29, 2013

tab completion for sudo

In order to enable tab completion for sudo, use the following command:
> complete -cf sudo
You can add it to ~/.bashrc for instance to activate this feature each
time you use bash.

August 20, 2013

rotate PDF files with pdftk

An easy way to rotate PDF files is to use the 'pdftk' toolkit.
Thus, in order to rotate all the pages of the document INPUT_FILE by 90 degrees clockwise (to the east) and save the output in OUTPUT_FILE, use the following command:
pdftk INPUT_FILE cat 1-endE output OUTPUT_FILE