pdf-tools-org is an emacs package that provides integration between pdf-tools and org-mode. The main features are importing and exporting pdf annotations from/to org files.
- clone this repo to $PACKAGEDIR:
cd $PACKAGEDIR
git clone https://github.com/pinguim06/pdf-tools-org
- add initialization your .emacs
(add-to-list 'load-path "$PACKAGEDIR/pdf-tools-org")
(require 'pdf-tools-org)
- if you want to auto export the annotations after saving a pdf, also add this:
(add-hook 'after-save-hook
(lambda ()
(when (eq major-mode 'pdf-view-mode) (pdf-tools-org-export-to-org))))
- Use
(pdf-tools-org-export-to-org)
to export annotations of current pdf file being viewed in PDFView mode to an org file. - Use
(pdf-tools-org-import-from-org ORGFILE)
to import annotations from ORGFILE.
- Importing is not working quite well yet – multiple annotations may be merged into one and multiple imports may create duplicates.