Does anyone know why the filecontents
environment was introduced?
What is the purpose of packing it all in one file, but without using a tarball?
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It only takes a minute to sign up.
Sign up to join this communityIt's a natural extension of the ideas of docstrip
that extracts comments and writes out the .sty
and .cls
files of the LaTeX distribution. It could have been written in perl or something but writing it in TeX makes it more portable to anyone who has tex at all.
Note that in 1991-1993 while latex2e was being developed, perl (introduced 1987) and a portable zip (info-zip introduced 1989) were not as commonly installed as they are today. Even now it is much easier to add small .csv
data files or local .sty
files to examples posted to this site by using filecontents
than it is to post them as separate files and have to give instructions about saving and file names, or posting to some other site as a zip or tar file and then hoping people on windows can unpack it.
comp.text(.tex)
but it's the same questions, just recycled:-)
Mar 26, 2013 at 23:02
filecontents
keeps everything together in one.tex
file.source2e
documentation, p 361): "The environmentfilecontents
is intended for passing the contents of packages, options, or other files along with a document in a single file.".eps
file inclusion. : tex.stackexchange.com/questions/47341/…