How to install it
Coauthor: Use subversion together with the svn_tunnel script (CNS computers homepage) to check out the repositories dasbuch and ChaosBook from the CNS svn server, Georgia Tech. Linux/unix instructions areThe LaTeX files are in dasbuch repository, while the webpages are in ChaosBook repository.cd ~/
svn_tunnel -b cnsuser
svn co svn://localhost:22369/dasbuch
cd ~/dasbuch/
svn co svn://localhost:22369/ChaosBook
mv ChaosBook WWW
Not linux? Microsoft and Apple are equally easy, read the above CNS homepagesNot crucial, but might be helpful: add the TEXINPUTS path by inserting line
setenv TEXINPUTS ./:..::$HOME/dasbuch/book/:$HOME/dasbuch/book/inputs/into your .cshrc (or corresponding file for your preferred shell).
How to TeX it
cd ~/dasbuch/bookThing will run if you have up-to-date CTAN TeX distribution and right paths.
latex book.tex
Edit the version number, version date inPreparing the public web book. pdf~/dasbuch/book/chapter/version.tex .edit ~/dasbuch/book/book.typ for a public PostScript version, executelatex book.texEdit ~/dasbuch/book/bin/mkbook contents and intro page ranges by hand if necessary, make sure that your unix has psnup (multiple pages per each sheet of paper) PostScript script, then execute (if you do not have ~/tmp/DasBuch directory already)mkdir ~/tmp/DasBuchthe PostScript version of all chapters marked by \forMkbook in book.tex main file is generated, compressed , and moved to the
~/dasbuch/book/bin/mkbook~/dasbuch/WWW/chapters/ directory.
Edit ~/dasbuch/book/book.typ for a public pdef version, thenmkdir ~/tmp/DasBuchwww.nbi.dk/ChaosBook/book.ps.gz is ready for transfer to Windows.
~/dasbuch/book/bin/mkpdfUse Adobe destiller to convert to hyperlinked book.pdf.
Adobe Destiller 4.0 configuration:then drag book.ps into Destiller
all fonts embedded
compatibility: Acrobat 3.0
joboption: TexOptimized (PressOptimized if TexOptimized not there)transfer the result to
cns.physics.gatech.edu:~chaosbook/WWW/book.pdfto have the byteserver version working
Preparing the coauthors version, raw (full, unedited) text chapter by chapter
Edit the version date inHow to back it all up~/dasbuch/WWW/boyscouts/index.htmland edit ~/dasbuch/book/book.typ for a coauthors version{preliminary} %% include margin comments, \Preliminary{...} partsexecute
% {public} %% omit margin comments, \Preliminary{...} parts
% UPDATE THIS!
{pdf} %% prepare HyperTeX pdf file
{postscript} %% prepare PostScript filelatex book.texEdit ~/dasbuch/book/bin/mkbookBoyscout contents and intro page ranges by hand if necessary,
then executemkdir ~/tmp/DasBuchthe PostScript version of all chapters marked by \forMkbook in book.tex main file, as well as the 3-volume complete book is generated, compressed , and moved to the
~/dasbuch/book/bin/mkbookBoyscout~/dasbuch/WWW/boyscouts/chapters/ directory.
Postscript fonts on shell.nbi.dkdo not worry, any single past edit can be retrieved from subversion
Gabor counseling by Andreas
How to print it
use filter psbook
on alf.nbi.dk 2-page per page printout - US letter format - is generated by
psnup -2 -pletter -m5pt flows.ps > ! flows2.ps
(not sure about the margin -m5pt)
on linux machines, this should work
alias ps2 'mpage -2 -m2 \!* > 2p-\!* ' generate 2p-filename.ps
alias lps2 'mpage -2 -m2 \!* | lpr ' send it to printer
Updating a WWW chapter
mkchap is a shell script that will generate the PostScript for a chapter, compress it, and move it to the ~DasBuch/WWW/chapters directory. Execute
mkchap chap4 97-110
to create a file called chap4.ps.gz with pages 97 through 110 from book.dvi
How to index it
run latex book twice having setShort versions\setboolean{display_comments}{false}
(do not know why otherwise index file is empty?). To update the index, type
makeindex bookthenlatex book.texagain so the latest version is included in the book.dviThe file short.tex allows you to latex just one input file with all the definitions in place. It is useful for testing out new environments or definitions.Changing the permissionsThere are two useful programs in the bin sub-directory for changing the permissions of a file. The program cmplxg will change the permissions of a file given to it as an argument. This works for any file owned by DasBuch and can be run by anyone in the nbicmplx group. So ifPreparing version for coauthors
alf> ls -l book.booand one runs
---x-wxr-x 1 dasbuch DasBuch 0 Dec 16 11:43 book.boo*alf> cmplxg book.boothe group permissions will change to 660alf> ls -l book.booThe script allgrp, also in the bin sub-directory does it for all the relevant files.
-rw-rw---- 1 dasbuch DasBuch 0 Dec 16 11:43 book.booIn book.tex edit ~/dasbuch/book/inputs/privateType.tex for a coauthor print on paper version, thenPutting your signiture in the footermkdir ~/tmp/DasBuchthe full, unedited ChaosBook.org/boyscouts/bookRaw.ps.gz and bookRaw-2p.ps.gz (2 page per page version - needs fixing) are ready for your perusal.
~/dasbuch/book/bin/mkpdfRawIf you want to put your own text into the page footer, create basedirectory.tex in your TEXINPUTS path, and edit the basedirectory lines in book/inputs/def.texCreate basedirectory.tex in your TEXINPUTS path by inserting line
setenv TEXINPUTS ./:..::$HOME/tex/texinputs/:$HOME/DasBuch/book/:$HOME/dasbuch/book/inputs/
into your .cshrc, or into your .login. In your tex/texinputs/ (or wherever you keep this) there should be a file called basedirectory.tex with the line\providecommand{\basedirectory}{your_machine_name^^40bookfile}The ^^40 is just a way of getting @. This way, when the files are LaTeX'ed the little footnote indicating the name of the file will be dependendent on the machine it was done.This file should not be in the ~/dasbuch/book subdirectory.
After that, go to the main book directory ~DasBuch/book and type
latex book.texand see it fly.
To get Postscript fonts on shell, produce the dvi file as usual, then when you go to produce the postscript with dvips, use the flags -Pcmz and Pamz, as indvips book -z -Pamz -Pcmz -o book.psThe -z flag is there to keep all the hyperlinks.