<div dir="ltr">The code of the whole TeXBook is on CTAN at <a href="http://tug.ctan.org/cgi-bin/ctanPackageInformation.py?id=texbook">http://tug.ctan.org/cgi-bin/ctanPackageInformation.py?id=texbook</a><br><br>But it is just there as an example of the business of writing a book in TeX and you should not TeX it. In fact at the beginning of the file Knuth says<br>
<br>% This manual is copyright (C) 1984 by the American Mathematical Society.<br>% All rights are reserved!<br>% The file is distributed only for people to see its examples of TeX input,<br>% not for use in the preparation of books like The TeXbook.<br>
% Permission for any other use of this file must be obtained in writing<br>% from the copyright holder and also from the publisher (Addison-Wesley).<br></div>