emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Alain.Cochard@unistra.fr
To: Leo Butler <Leo.Butler@umanitoba.ca>
Cc: Org Mode Mailing List <emacs-orgmode@gnu.org>
Subject: Re: setting export_file_name during export
Date: Fri, 6 Jan 2023 23:15:20 +0100	[thread overview]
Message-ID: <25528.40312.882538.752027@gargle.gargle.HOWL> (raw)
In-Reply-To: <87bknbs5qn.fsf@t14.reltub.ca>

Leo Butler writes on Fri  6 Jan 2023 21:38:
 > Hello,
 > 
 > I am trying something new this semester: all my lecture notes are
 > organized into a single org file. A minor problem: I want to export each
 > lecture (see below) as a separate pdf file. I would like to know if
 > anyone has ``solved'' this problem or has a suggestion on how to do it.
 > 
 > Ideally, I would like to have a single function that retains only the
 > current subtree that contains point, sets EXPORT_FILE_NAME based on the
 > top heading, and exports it as a complete beamer pdf.

Hi.  Sorry if you already know this and want something more automated
it is not too clear to me.  (What is not clear either is why you have
'* Lecture 1' _and_ '** Lecture 1', etc., i.e., why not just
'* Lecture 1'.)

So: if you insert 

  :PROPERTIES:
  :EXPORT_FILE_NAME: lecture-1.pdf
  :END:

right after '** Lecture 1' and, with the point inside that subtree,
do:

  C-c C-e C-s l O

it seems to me it does the job.

 > #+AUTHOR: Leo Butler
 > #+TITLE: Lectures in Math
 > #+OPTIONS: H:2 toc:t num:t
 > #+LATEX_CLASS: beamer
 > #+LATEX_CLASS_OPTIONS: [presentation]
 > #+STARTUP: beamer
 > #+EXPORT_FILE_NAME: lectures
 > 
 > * Lecture 1
 > ** Lecture 1
 > In the beginning...This subtree should be exported to =lecture-1.pdf=.
 > * Lecture 2
 > ** Lecture 2
 > Next...This subtree should be exported to =lecture-2.pdf=.

-- 
EOST (École et Observatoire des Sciences de la Terre) 
ITE (Institut Terre & Environnement) | alain.cochard@unistra.fr
5 rue René Descartes   [bureau 110]  | Phone: +33 (0)3 68 85 50 44 
F-67084 Strasbourg Cedex, France     | [ slot available for rent ]



  reply	other threads:[~2023-01-06 22:16 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-06 21:38 setting export_file_name during export Leo Butler
2023-01-06 22:15 ` Alain.Cochard [this message]
2023-01-06 22:52   ` Leo Butler
2023-01-06 23:03     ` Alain.Cochard
2023-01-10 16:46     ` Nick Dokos
2023-01-10 20:01       ` Leo Butler

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=25528.40312.882538.752027@gargle.gargle.HOWL \
    --to=alain.cochard@unistra.fr \
    --cc=Leo.Butler@umanitoba.ca \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).