|
From: Mojca M. <moj...@gm...> - 2011-09-12 07:09:53
|
On Sun, Sep 11, 2011 at 18:41, Ethan Merritt wrote:
> On Sunday, 11 September 2011, Mojca Miklavec wrote:
>>
>> Should gnuplot-lua-tikz.sty be removed from CVS (if it is
>> auto-generated)?
>
> See above. It was removed from CVS long ago.
Mea culpa. (I'm very sorry.)
I hate CVS so much that I use the repository converted into git:
https://github.com/gnuplot/gnuplot/
I'm using
git cvsimport -C $PWD/git/gnuplot.git -p x -d $PWD/cvs/gnuplot gnuplot
inside a cron job and it seems that the command "forgot" to remove some files.
In 99.9% of cases it works perfectly fine, but it seems that in this
case it didn't do the job properly. I will try to inspect why this
happens. It could be a bug in git or something unexpected that I did
at my side.
Somebody else's clone doesn't seem to suffer from this
(https://github.com/Reen/gnuplot/tree/master/share/LaTeX). The irony
is that I'm also using a clone of his repository, but in that one I
messed with inclusion of TikZ myself, so that this particular file
remained there as a consequence of my own commits.
Thank you for pointing this out and sorry for asking about things that
were wrong at my end.
>> Why is pdffigures.tex included in CVS if it is built during "make pdf" anyway?
>
> The comment you quote attempts to explain this.
> The top-level file titlepag.tex contains a line
> \include{pdffigures}
> In order to toggle whether or not the figure-generation code is
> _really_ used, the Makefile either creates appropriate file contents
> for pdffigures.tex or creates an empty file with that name.
>
> Perhaps someone more knowledgeable in TeX syntax knows how make the
> latex "\include" statement conditional on some external variable,
> which would be an alternative way to accomplish the same thing.
Please try the following:
\documentclass{article}
\begin{document}
\ifx\printmode\undefined
{document without figures}
\write16{NOOOOOOOOOO}
\else
{this document has figures}
\write16{YEEEEEEEEES}
\fi
\end{document}
You can then compile it with
pdflatex "\\def\\printmode{$SOMEVARIABLE}\\input{filename.tex}"
or simply with
pdflatex '\def\\printmode{figures}\input{filename.tex}'
when you want figures and with
pdflatex filename.tex
when you don't. Note that the code above only tests if the command
sequence has been defined, so figures will be generated no matter what
you put into $SOMEVARIABLE. You could also compare contents, but in
this case there is no need to do so in this particular case (it would
be bad if you required to use the complicated sequence to compile the
default document).
In practice you could replace
\include{pdffigures}
with
\ifx\printmode\undefined\else
\usepackage{graphicx}
\usepackage{picins}
\fi
and then call
pdflatex '\def\printmode{figures}\input{gnuplot.tex}'
Alternatively you could create gnuplot-figures.tex with
\def\printmode{figures}
\input gnuplot.tex
and compile with
pdflatex gnuplot-figures.tex
instead of
pdflatex '\def\\printmode{figures}\input{gnuplot.tex}'
This would of course give you gnuplot-figures.tex.
Mojca
|