I want to use the exact same file for my beamer presentation and handout. I do not like the need to comment out lines in order to create the handout or presentation (my current solution), nor do I want to have multiple files with an \input command. I realized that I can have a link (I work in linux or bsd) pointing to my main file, say
talk_handout.tex -> talk.tex
then the macro \jobname will let me know if I'm compiling the main file or the link. Using \endswith from the xifthen package I could then figure out if I should do handout or presentation mode.
This is all nice in theory, but in practice I have no idea how to do this. I usually have either [handout] or [beamer] in my \documentclass line and I don't know how to combine that with my desired use of \jobname.
Of course, I could have two files with an \input command right after the \documentclass line ... but I was wondering if there's another way.
Any ideas?
\include. But, perhaps you could explain why this is not a good solution... – Seamus Nov 24 '10 at 16:22\input, not\include... – Jukka Suomela Nov 24 '10 at 20:11.texfile emacs asks me what I want the master file to be, so that's not a problem. I have no problem with file clutter. It's not like I actually look through the folders where I store my tex documents regularly. Each file compiles (with the master document trick)... – Seamus Nov 25 '10 at 13:22