]> git.lyx.org Git - lyx.git/blobdiff - src/tex2lyx/tex2lyx.1in
Add -copyfiles command line option to tex2lyx
[lyx.git] / src / tex2lyx / tex2lyx.1in
index 028f10c9068ac58aceac9fdff22b8bb0cd45045a..b430909f030931363a23e93b7cec22f286927337 100644 (file)
@@ -21,7 +21,7 @@ options.
 .PP
 \fBtex2lyx\fR [ \fB\-userdir\fR \fIuserdir\fR ] [ \fB\-systemdir\fR \fIsystemdir\fR ]
 [ \fB\-n\fR ] [ \fB\-c\fR \fItextclass\fR ] [\ \fB\-s\fR\ \fIsfile1\fR[,\fIsfile2\fR...]] [
-\fB\-roundtrip\fR ] \fIinputfile\fR [ \fIoutputfile\fR ]
+\fB\-roundtrip\fR ] [ \fB\-copyfiles\fR ] \fIinputfile\fR [ \fIoutputfile\fR ]
 .\" .PP
 .\" \fBtex2lyx\fR [ \fB\-userdir\fR \fIuserdir\fR ] [ \fB\-systemdir\fR \fIsystemdir\fR ]
 .\" [\ \fB\-r\fR\ \fIrenv1\fR[,\fIrenv2\fR...]] [\ \fB\-s\fR\ \fIsfile1\fR[,\fIsfile2\fR...]]
@@ -34,6 +34,11 @@ creates a file of textclass \*[lq]foo\*[rq] and reads the LyX layout file for th
 (something like /usr/local/share/lyx/layouts/foo.layout \s-1OR\s0
 \fB\s-1HOME\s0\fR/.lyx/layouts/foo.layout).  Use \fB\-c\fR to declare a different textclass
 (and read a different layout file).
+.IP ""
+This option is needed if the input file is a LaTeX fragment, with no preamble
+matter or \f(CW\ebegin{document}\fR command. LyX files created by
+\fBtex2lyx\fR from partial files can be included in an existing LyX file using
+the \*[lq]Include LyX File\*[rq] command from LyX's Insert menu.
 .TP
 .BI \-f
 Force. \fBtex2lyx\fR will not run if the .lyx file it would generate already exists.
@@ -44,16 +49,6 @@ Noweb. Translate a noweb (aka literate programming) file. This should be
 (almost?) equivalent to running \*[lq]noweb2lyx foo.tex foo.lyx\*[rq]. This option
 requires the \fB\-c\fR option.
 .\" .TP
-.\" .BI \-p
-.\" Partial file. The input files are LaTeX fragments, with no preamble matter or
-.\" \f(CW\ebegin{document}\fR commands. This option requires the \fB\-c\fR option, since there
-.\" are no \f(CW\edocumentclass\fR commands in the files \fBtex2lyx\fR is translating. When
-.\" using this option, you can translate more than one file, as long as all files
-.\" are the same class. The LyX file created by \fBtex2lyx\fR can be included in an
-.\" existing LyX file using the \*[lq]Include LyX File\*[rq] command from
-.\" LyX's Insert menu. (\fBNOTE\fR: this feature of the older \fBreLyX\fR script has
-.\" not yet been implemented in \fBtex2lyx\fR).
-.\" .TP
 .\" .BI \-r
 .\" Regular environments (see the section on \fISyntax Files\fR).  If you give more than one
 .\" environment, separate them with commas (not spaces). You'll probably need to
@@ -75,12 +70,21 @@ Specify a user directory. Normally, you shouldn't need this. Your LyX user direc
 chosen. Cf. the section \f(CWFILES\fR for details.
 .TP
 .BI \-roundtrip
-Call LyX to re-export the created output file to LaTeX. The output file name
-is always determined automatically to avoid over-writing the input file by
-accident: If the input file is named \fIfoo.tex\fR the output file will be
+Call LyX to re-export the created output file to LaTeX. If the output file name
+is not given it is determined automatically to avoid over-writing the input file
+by accident: If the input file is named \fIfoo.tex\fR the output file will be
 named \fIfoo.lyx.lyx\fR, and the re-exported file will be named
 \fIfoo.lyx.tex\fR.
 .TP
+.BI \-copyfiles
+Copy all included files below the input directory and that \fBtex2lyx\fR is
+aware of to the output directory if the output file is located in a different
+directory than the input file. This is useful if you want to ensure that no
+included file is overwritten (either in roundtrip mode or by a later export
+from LyX). Please note that the resulting document may be uncompilable. This
+happens if it needs files that \fBtex2lyx\fR does not know about and therefore
+does not copy to the output directory.
+.TP
 .BI \-help
 Help. Print out usage information and quit.
 .TP
@@ -120,7 +124,7 @@ Run \fBtex2lyx\fR.
 you don't want any output at all, try (in csh) `tex2lyx foo.tex >& /dev/null'.
 You should \s-1NOT\s0 redirect standard output to \fIfoo.lyx\fR.
 .IP "\(bu" 4
-Run LyX (version 1.6 or later) on the resulting .lyx file.
+Run LyX (version 2.1 or later) on the resulting .lyx file.
 .IP ""
 In theory, most of the file will have been translated, and anything that's
 untranslatable will be transferred to TeX code (ERT in LyX-speak). In theory, LyX will be