Skip to content

healthypackrat/pdf_outline_editor

Repository files navigation

pdf_outline_editor

Build Status

This gem provides a command to get/set PDF outlines from a JSON/YAML definition file.

Useful for PDF files which don't have outlines.

Requirements

  • JRuby

Installation

$ jgem install pdf_outline_editor

Usage

First, generate an outlines definition file by running init command:

$ pdf_outline_editor init -f json > toc.json

or, by running dump command with an existing pdf file:

$ pdf_outline_editor dump -f json input.pdf > toc.json

(Edit toc.json as you like...)

Then run load command to set outlines:

$ pdf_outline_editor load input.pdf toc.json output.pdf

Development

Run bin/rspec to run the specs.

Run bin/rubocop to check formattings.

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/healthypackrat/pdf_outline_editor.

License

The gem is available as open source under the terms of the Apache License, Version 2.0.