Posted almost 7 years ago. Visible to the public.

Rotate a PDF under Ubuntu Linux

Use the PDF toolkit:

Copy
sudo apt-get install pdftk

To rotate page 1 by 90 degrees clockwise:

Copy
pdftk in.pdf cat 1E output out.pdf # old pdftk pdftk in.pdf cat 1east output out.pdf # new pdftk

To rotate all pages clockwise:

Copy
pdftk in.pdf cat 1-endE output out.pdf # old pdftk pdftk in.pdf cat 1-endeast output out.pdf # new pdftk

The E (old pdftk) or east (new pdftk) is meaningful if you want other rotations. From the man page:

The page rotation setting can cause pdftk to rotate pages and documents.
Each option sets the page rotation as follows (in degrees): north: 0, east: 90, south: 180, west: 270, left: -90, right: +90, down: +180. left, right, and down make relative adjustments to a page's rotation.

Growing Rails Applications in Practice
Check out our new e-book:
Learn to structure large Ruby on Rails codebases with the tools you already know and love.

Author of this card:

Avatar
Henning Koch
Last edit:
over 3 years ago
by Henning Koch
About this deck:
We are makandra and do test-driven, agile Ruby on Rails software development.
License for source code
Posted by Henning Koch to makandra dev
This website uses cookies to improve usability and analyze traffic.
Accept or learn more