[emacs-berlin] Understanding Orgmode publish project to PDF

jman emacs-berlin at city17.xyz
Sun Jan 21 23:19:46 UTC 2024


Hello everyone,

I have an orgmode index file that links to other orgmode files. Is there a way to export the project to PDF and automatically have the PDF files reference each other? Example:

Content of the index file:
----------s---------s----------
This is the index file. Go to File 1 [[file:file1.org]]
----------e---------e----------

Content of the linked file1.org:
----------s---------s----------
Content of File 1. Go back to [[file:index.org]]
----------e---------e----------

I export the entire project to PDF with `M-x org-publish-current-project` and the following config:
----------s---------s----------
(setq org-publish-project-alist
      '(
        ("My Project"
         :base-directory "/home/me/orgmode/"
         :base-extension "org"
         :publishing-directory "/home/me/orgmode/pdf/"
         :publishing-function org-latex-publish-to-pdf
         :body-only nil
         )
        )
      )
----------e---------e----------

The exported PDF files have links pointing to the orgmode files. Instead, I would like the export process to be smart and change the links to reference the PDF files.

Note that if I use the publishing function `org-html-publish-to-html`, links in the HTML generated files are converted to the proper output extension, thus pointing to an HTML file.

I wonder if I am missing something or it is just not implemented.

Thanks for any hint!


More information about the emacs-berlin mailing list