Sketch2PDF—Sketch Plugin For One-click Export, Merge & Optimization of PDFs

Joro Yordanov
Mar 26, 2018 · 3 min read

The Problem

Recently we had this large design project at Oblik Studio—we had to design an identity and branding as well as a website and a set of various digital materials. One of them was a pitch deck for the product, which we decided to design using Sketch, since our Design System was already set there.

The workflow was:

  1. Design each slide on a separate artboard in Sketch
  2. Export all artboards as PDFs
  3. Combine all PDFs in one using Acrobat Reader
  4. Optimize the file size in Acrobat Reader

Working on a PDF presentation that is constantly being improved and published, means that you have to go through all of these 4 steps a few times per day which is not only annoying but it is also very time-consuming.

Therefore, the whole process should be streamlined in a much simpler workflow.

The Solution

A demo showing how it works with a few slides for

Firstly, I started by using Terminal to merge all separate PDF files into a single one by running a Python script that comes with the macOS Automator.

Then I found a way to optimize the file size with ps2pdf, which is a part of Ghostcript, by running a Terminal command.

Still — I had to run two commands after the PDF export is completed.

I realized that there must have been a way to auto run these commands on something like a hook. Consequently, that hook must have been triggered when one uses the built in export functionality of Sketch; and I found SVGO Export.

By reusing a part of its codebase, I was able to create a simple, no-GUI plugin that automates the whole process of exporting, merging and optimizing PDFs.

Oblik Studio is a cross-disciplinary design studio. If you are looking for a design partner, get in touch.

Oblik Studio

a cross-disciplinary design studio and the people behind it

Joro Yordanov

Written by

interactive designer with no eye bags

Oblik Studio

a cross-disciplinary design studio and the people behind it

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade