emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* latex options
@ 2015-03-30  9:28 Zhihao Ding
  2015-03-30 10:32 ` Andreas Leha
  0 siblings, 1 reply; 3+ messages in thread
From: Zhihao Ding @ 2015-03-30  9:28 UTC (permalink / raw)
  To: emacs-orgmode@gnu.org

Dear Org experts, 

I was wondering if anyone could advise on this simple problem.
My toy org file, shown as below, contains 3 projects. I’d like to  
export beamer PDFs for individual projects from time to time, 
but the pain is that I always need to modify the header options  
(title, select_tags etc) to match the project that I want to export. 

The question is what the best way is to organise the options for 
multiple projects? Ideally I’d like to put a copy of the options 
under each project, so that I only need to define them once. 
It’d be even better if I could specify the file that I want the project
to be exported to instead of the same pdf file matching my org
file.

#+TITLE: mytitle
#+AUTHOR: myself
#+DATE: \today
#+LaTeX_CLASS: mybeamer
#+SELECT_TAGS: export
#+EXCLUDE_TAGS: noexport
#+OPTIONS: H:4 toc:nil *:

** project 1
** project 2
** project 3

Thanks a lot!

Zhihao


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: latex options
  2015-03-30  9:28 latex options Zhihao Ding
@ 2015-03-30 10:32 ` Andreas Leha
  2015-03-30 10:56   ` Zhihao Ding
  0 siblings, 1 reply; 3+ messages in thread
From: Andreas Leha @ 2015-03-30 10:32 UTC (permalink / raw)
  To: emacs-orgmode

Hi Zhihao,

Zhihao Ding <zhihao.ding@imm.ox.ac.uk> writes:
> Dear Org experts, 
>
> I was wondering if anyone could advise on this simple problem.
> My toy org file, shown as below, contains 3 projects. I’d like to  
> export beamer PDFs for individual projects from time to time, 
> but the pain is that I always need to modify the header options  
> (title, select_tags etc) to match the project that I want to export. 
>
> The question is what the best way is to organise the options for 
> multiple projects? Ideally I’d like to put a copy of the options 
> under each project, so that I only need to define them once. 
> It’d be even better if I could specify the file that I want the project
> to be exported to instead of the same pdf file matching my org
> file.
>
> #+TITLE: mytitle
> #+AUTHOR: myself
>
> #+DATE: \today
> #+LaTeX_CLASS: mybeamer
>
> #+SELECT_TAGS: export
> #+EXCLUDE_TAGS: noexport
>
> #+OPTIONS: H:4 toc:nil *:
>
> ** project 1
> ** project 2
> ** project 3
>

You can add most of these keywords to the properties of a subtree by
prepending them with 'export_'.  I am not sure about the select tags,
though.  Why do you need them to differ between the projects?


Your Example:


--8<---------------cut here---------------start------------->8---
#+TITLE: mytitle
#+AUTHOR: myself

#+DATE: \today
#+LaTeX_CLASS: mybeamer

#+SELECT_TAGS: export
#+EXCLUDE_TAGS: noexport

#+OPTIONS: H:4 toc:nil *:

** project 1
:PROPERTIES:
:header-args:R: :session *mysession1*
:header-args: :cache yes
:EXPORT_TITLE: mytitle 1
:EXPORT_LaTeX_HEADER: \subtitle{mysubtitle 1}
:EXPORT_FILE_NAME: myfile1
:EXPORT_DATE: mydate 1
:EXPORT_LaTeX_CLASS: mybeamer 1
:EXPORT_OPTIONS: H:2 toc:nil
:END:
** project 2
:PROPERTIES:
:header-args:R: :session *mysession2*
:header-args: :cache yes
:EXPORT_TITLE: mytitle 2
:EXPORT_LaTeX_HEADER: \subtitle{mysubtitle 2}
:EXPORT_FILE_NAME: myfile2
:EXPORT_DATE: mydate 2
:EXPORT_LaTeX_CLASS: mybeamer 2
:EXPORT_OPTIONS: H:2 toc:nil
:END:
** project 3
:PROPERTIES:
:header-args:R: :session *mysession3*
:header-args: :cache yes
:EXPORT_TITLE: mytitle 3
:EXPORT_LaTeX_HEADER: \subtitle{mysubtitle 3}
:EXPORT_FILE_NAME: myfile3
:EXPORT_DATE: mydate 3
:EXPORT_LaTeX_CLASS: mybeamer 3
:EXPORT_OPTIONS: H:2 toc:nil
:END:
--8<---------------cut here---------------end--------------->8---


HTH,
Andreas

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: latex options
  2015-03-30 10:32 ` Andreas Leha
@ 2015-03-30 10:56   ` Zhihao Ding
  0 siblings, 0 replies; 3+ messages in thread
From: Zhihao Ding @ 2015-03-30 10:56 UTC (permalink / raw)
  To: Andreas Leha; +Cc: emacs-orgmode@gnu.org

Thanks Andreas! This is very helpful. 

I am using tags to control how verbose I want my export to be 
and currently they differ slightly between projects. Quite often 
I also have project specific tags. But no problem I think that’s 
manageable with the layout you suggested. 

Best, 
Zhihao


> On 30 Mar 2015, at 11:32, Andreas Leha <andreas.leha@med.uni-goettingen.de> wrote:
> 
> Hi Zhihao,
> 
> Zhihao Ding <zhihao.ding@imm.ox.ac.uk> writes:
>> Dear Org experts, 
>> 
>> I was wondering if anyone could advise on this simple problem.
>> My toy org file, shown as below, contains 3 projects. I’d like to  
>> export beamer PDFs for individual projects from time to time, 
>> but the pain is that I always need to modify the header options  
>> (title, select_tags etc) to match the project that I want to export. 
>> 
>> The question is what the best way is to organise the options for 
>> multiple projects? Ideally I’d like to put a copy of the options 
>> under each project, so that I only need to define them once. 
>> It’d be even better if I could specify the file that I want the project
>> to be exported to instead of the same pdf file matching my org
>> file.
>> 
>> #+TITLE: mytitle
>> #+AUTHOR: myself
>> 
>> #+DATE: \today
>> #+LaTeX_CLASS: mybeamer
>> 
>> #+SELECT_TAGS: export
>> #+EXCLUDE_TAGS: noexport
>> 
>> #+OPTIONS: H:4 toc:nil *:
>> 
>> ** project 1
>> ** project 2
>> ** project 3
>> 
> 
> You can add most of these keywords to the properties of a subtree by
> prepending them with 'export_'.  I am not sure about the select tags,
> though.  Why do you need them to differ between the projects?
> 
> 
> Your Example:
> 
> 
> --8<---------------cut here---------------start------------->8---
> #+TITLE: mytitle
> #+AUTHOR: myself
> 
> #+DATE: \today
> #+LaTeX_CLASS: mybeamer
> 
> #+SELECT_TAGS: export
> #+EXCLUDE_TAGS: noexport
> 
> #+OPTIONS: H:4 toc:nil *:
> 
> ** project 1
> :PROPERTIES:
> :header-args:R: :session *mysession1*
> :header-args: :cache yes
> :EXPORT_TITLE: mytitle 1
> :EXPORT_LaTeX_HEADER: \subtitle{mysubtitle 1}
> :EXPORT_FILE_NAME: myfile1
> :EXPORT_DATE: mydate 1
> :EXPORT_LaTeX_CLASS: mybeamer 1
> :EXPORT_OPTIONS: H:2 toc:nil
> :END:
> ** project 2
> :PROPERTIES:
> :header-args:R: :session *mysession2*
> :header-args: :cache yes
> :EXPORT_TITLE: mytitle 2
> :EXPORT_LaTeX_HEADER: \subtitle{mysubtitle 2}
> :EXPORT_FILE_NAME: myfile2
> :EXPORT_DATE: mydate 2
> :EXPORT_LaTeX_CLASS: mybeamer 2
> :EXPORT_OPTIONS: H:2 toc:nil
> :END:
> ** project 3
> :PROPERTIES:
> :header-args:R: :session *mysession3*
> :header-args: :cache yes
> :EXPORT_TITLE: mytitle 3
> :EXPORT_LaTeX_HEADER: \subtitle{mysubtitle 3}
> :EXPORT_FILE_NAME: myfile3
> :EXPORT_DATE: mydate 3
> :EXPORT_LaTeX_CLASS: mybeamer 3
> :EXPORT_OPTIONS: H:2 toc:nil
> :END:
> --8<---------------cut here---------------end--------------->8---
> 
> 
> HTH,
> Andreas


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-03-30 10:56 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-03-30  9:28 latex options Zhihao Ding
2015-03-30 10:32 ` Andreas Leha
2015-03-30 10:56   ` Zhihao Ding

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).