On Tue, Dec 15, 1998 at 02:57:20PM +0100, Lars Gullik Bjønnes wrote:
>
> | However, note that we still need to write the temporary files. We
> | *can* write them in /tmp, but alternatively, we can just write them
> | to tmp_dir. Since they're erased anyway (unless you're running with
>
> One problem as of now, is that reLyX does not know where lyx_dir is.
>
> | Wow! This seems really easy. Should I add the -o option?
>
> Why not?
True. That is a problem. But I think we can get around it. My current plan is
that if we get a -o, then ALL temp files & lyx files go in the directory
specified by -o, since it's guaranteed to be writable. This includes included
files (\include).
Unfortunately, this doesn't entirely solve our problem. What about the -p
option? That allows you to input a number of files that you want to translate.
Obviously you can't input a -o option for each one! But this means that you're
not allowed to include any files from read-only directories in your list of
files for the -p option.
I was thinking of having the -o option give the output *directory* instead of
the output filename. That would solve the -p problem. But that seems a little
non-intuitive, since you then don't get to pick the name of the output file.
>
> Perhaps there should be an option where to put the tmp files as well?
>
Sigh. I don't know that this will fix things. It's not really important to say
where the temp files go, since they automatically get erased anyway, at the
end of the reLyX run. And I'd like to keep from adding options to reLyX except
when necessary.
By the way, there's yet another problem. The -p option creates LyX files which
don't get erased. Theoretically, in the future, you'll be able to import a
latex fragment (via cut & paste? Well, at least via Import->LaTeX Fragment),
which will call 'reLyX -fp -c "whatever the current textclass is" file.tex'.
(Hm. So for cut & paste, I guess reLyX will have to read from stdin? Yuck.
Let's postpone that.) If use_tempdir is false, then a foo.lyx file will be
created and not deleted. Again, we *could* make LyX worry about that, but
perhaps Asger will be annoyed by that.
This problem is getting way too complicated. Some would probably say that I
neglected to think of certain design issues before writing reLyX. Too bad they
would be right. Anyway, suggestions would be appreciated.
-Amir