diff --git a/en_US.ISO8859-1/books/fdp-primer/book.sgml b/en_US.ISO8859-1/books/fdp-primer/book.sgml index 26485ba9f9..d3cb1e1cb1 100644 --- a/en_US.ISO8859-1/books/fdp-primer/book.sgml +++ b/en_US.ISO8859-1/books/fdp-primer/book.sgml @@ -1,271 +1,273 @@ %bookinfo; + +%freebsd; %authors; %teams; %mailing-lists; %man; %urls; %chapters; ]> FreeBSD Documentation Project Primer for New Contributors The FreeBSD Documentation Project 1998 1999 2000 2001 2002 2003 2004 DocEng $FreeBSD$ $FreeBSD$ &bookinfo.legalnotice; Thank you for becoming a part of the FreeBSD Documentation Project. Your contribution is extremely valuable. This primer covers everything you will need to know in order to start contributing to the FreeBSD Documentation Project, from the tools and software you will be using (both mandatory and recommended) to the philosophy behind the Documentation Project. This document is a work in progress, and is not complete. Sections that are known to be incomplete are indicated with a * in their name. Preface Shell Prompts The following table shows the default system prompt and superuser prompt. The examples will use this prompt to indicate which user you should be running the example as. User Prompt Normal user &prompt.user; root &prompt.root; Typographic Conventions The following table describes the typographic conventions used in this book. Meaning Examples The name of commands, files, and directories. On screen computer output. Edit your .login file.Use ls -a to list all files.You have mail. What you type, when contrasted with on-screen computer output. &prompt.user; su Password: Manual page references. Use su 1 to change user names. User and group names Only root can do this. Emphasis You must do this. Command line variables; replace with the real name or variable. To delete a file, type rm filename Environment variables $HOME is your home directory. Notes, tips, important information, warnings, and examples Within the text appear notes, warnings, and examples. Notes are represented like this, and contain information that you should take note of, as it may affect what you do. Tips are represented like this, and contain information that you might find useful, or lead to an easier way to do something. Important information is represented like this. Typically they flag extra steps you may need to carry out. Warnings are represented like this, and contain information warning you about possible damage if you do not follow the instructions. This damage may be physical, to your hardware or to you, or it may be non-physical, such as the inadvertent deletion of important files. A sample example Examples are represented like this, and typically contain examples you should walk through, or show you what the results of a particular action should be. Acknowledgments My thanks to Sue Blake, Patrick Durusau, Jon Hamilton, Peter Flynn, and Christopher Maden, who took the time to read early drafts of this document and offer many valuable comments and criticisms. &chap.overview; &chap.tools; &chap.sgml-primer; &chap.sgml-markup; &chap.stylesheets; &chap.structure; &chap.doc-build; &chap.the-website; &chap.translations; &chap.writing-style; &chap.psgml-mode; &chap.see-also; &app.examples; diff --git a/en_US.ISO8859-1/books/fdp-primer/examples/appendix.sgml b/en_US.ISO8859-1/books/fdp-primer/examples/appendix.sgml index 67c051e207..7833d5d0bc 100644 --- a/en_US.ISO8859-1/books/fdp-primer/examples/appendix.sgml +++ b/en_US.ISO8859-1/books/fdp-primer/examples/appendix.sgml @@ -1,355 +1,355 @@ Examples This appendix contains example SGML files and command lines you can use to convert them from one output format to another. If you have successfully installed the Documentation Project tools then you should be able to use these examples directly. These examples are not exhaustive—they do not contain all the elements you might want to use, particularly in your document's front matter. For more examples of DocBook markup you should examine the SGML source for this and other documents, available in the CVSup doc collection, or available online starting at . To avoid confusion, these examples use the standard DocBook 4.1 DTD rather than the FreeBSD extension. They also use the stock stylesheets distributed by Norm Walsh, rather than any customisations made to those stylesheets by the FreeBSD Documentation Project. This makes them more useful as generic DocBook examples. DocBook <sgmltag>book</sgmltag> DocBook <sgmltag>book</sgmltag> An Example Book Your first name Your surname
foo@example.com
2000 Copyright string here If your book has an abstract then it should go here.
Preface Your book may have a preface, in which case it should be placed here. My first chapter This is the first chapter in my book. My first section This is the first section in my book.
]]>
DocBook <sgmltag>article</sgmltag> DocBook <sgmltag>article</sgmltag>
An example article Your first name Your surname
foo@example.com
2000 Copyright string here If your article has an abstract then it should go here.
My first section This is the first section in my article. My first sub-section This is the first sub-section in my article.
]]>
Producing formatted output This section assumes that you have installed the software listed in the textproc/docproj port, either by hand, or by using the port. Further, it is assumed that your software is installed in subdirectories under /usr/local/, and the directory where binaries have been installed is in your PATH. Adjust the paths as necessary for your system. Using Jade Converting DocBook to HTML (one large file) &prompt.user; jade -V nochunks \ -c /usr/local/share/sgml/docbook/dsssl/modular/catalog \ -c /usr/local/share/sgml/docbook/catalog \ -c /usr/local/share/sgml/jade/catalog \ -d /usr/local/share/sgml/docbook/dsssl/modular/html/docbook.dsl \ -t sgml file.sgml > file.html Specifies the nochunks parameter to the stylesheets, forcing all output to be written to STDOUT (using Norm Walsh's stylesheets). Specifies the catalogs that Jade will need to process. Three catalogs are required. The first is a catalog that contains information about the DSSSL stylesheets. The second contains information about the DocBook DTD. The third contains information specific to Jade. Specifies the full path to the DSSSL stylesheet that Jade will use when processing the document. Instructs Jade to perform a transformation from one DTD to another. In this case, the input is being transformed from the DocBook DTD to the HTML DTD. Specifies the file that Jade should process, and redirects output to the specified .html file. Converting DocBook to HTML (several small files) &prompt.user; jade \ -c /usr/local/share/sgml/docbook/dsssl/modular/catalog \ -c /usr/local/share/sgml/docbook/catalog \ -c /usr/local/share/sgml/jade/catalog \ -d /usr/local/share/sgml/docbook/dsssl/modular/html/docbook.dsl \ -t sgml file.sgml Specifies the catalogs that Jade will need to process. Three catalogs are required. The first is a catalog that contains information about the DSSSL stylesheets. The second contains information about the DocBook DTD. The third contains information specific to Jade. Specifies the full path to the DSSSL stylesheet that Jade will use when processing the document. Instructs Jade to perform a transformation from one DTD to another. In this case, the input is being transformed from the DocBook DTD to the HTML DTD. Specifies the file that Jade should process. The stylesheets determine how the individual HTML files will be named, and the name of the root file (i.e., the one that contains the start of the document. This example may still only generate one HTML file, depending on the structure of the document you are processing, and the stylesheet's rules for splitting output. Converting DocBook to Postscript - The source SGML file must be converted to a TeX file. + The source SGML file must be converted to a &tex; file. &prompt.user; jade -Vtex-backend \ -c /usr/local/share/sgml/docbook/dsssl/modular/catalog \ -c /usr/local/share/sgml/docbook/catalog \ -c /usr/local/share/sgml/jade/catalog \ -d /usr/local/share/sgml/docbook/dsssl/modular/print/docbook.dsl \ -t tex file.sgml Customises the stylesheets to use various options - specific to producing output for TeX. + specific to producing output for &tex;. Specifies the catalogs that Jade will need to process. Three catalogs are required. The first is a catalog that contains information about the DSSSL stylesheets. The second contains information about the DocBook DTD. The third contains information specific to Jade. Specifies the full path to the DSSSL stylesheet that Jade will use when processing the document. - Instructs Jade to convert the output to TeX. + Instructs Jade to convert the output to &tex;. The generated .tex file must now be run through tex, specifying the &jadetex macro package. &prompt.user; tex "&jadetex" file.tex You have to run tex at least three times. The first run processes the document, and determines areas of the document which are referenced from other parts of the document, for use in indexing, and so on. Do not be alarmed if you see warning messages such as LaTeX Warning: Reference `136' on page 5 undefined on input line 728. at this point. The second run reprocesses the document now that certain pieces of information are known (such as the document's page length). This allows index entries and other cross-references to be fixed up. The third pass performs any final cleanup necessary. The output from this stage will be file.dvi. Finally, run dvips to convert the .dvi file to Postscript. &prompt.user; dvips -o file.ps file.dvi Converting DocBook to PDF The first part of this process is identical to that when converting DocBook to Postscript, using the same jade command line (). When the .tex file has been generated you run pdfTeX. However, use the &pdfjadetex macro package instead. &prompt.user; pdftex "&pdfjadetex" file.tex Again, run this command three times. This will generate file.pdf, which does not need to be processed any further.
diff --git a/en_US.ISO8859-1/books/fdp-primer/tools/chapter.sgml b/en_US.ISO8859-1/books/fdp-primer/tools/chapter.sgml index a9490faf3d..3f5afc990f 100644 --- a/en_US.ISO8859-1/books/fdp-primer/tools/chapter.sgml +++ b/en_US.ISO8859-1/books/fdp-primer/tools/chapter.sgml @@ -1,291 +1,291 @@ Tools The FDP uses a number of different software tools to help manage the FreeBSD documentation, convert it to different output formats, and so on. You will need to use these tools yourself if you are to work with the FreeBSD documentation. All these tools are available as FreeBSD Ports and Packages, greatly simplifying the work you have to do to install them. You will need to install these tools before you work through any of the examples in later chapters. The actual usage of these tools is covered in later chapters. Use <filename role="package">textproc/docproj</filename> if possible You can save yourself a lot of time if you install the textproc/docproj port. This is a meta-port which does not contain any software itself. Instead, it depends on various other ports being installed correctly. Installing this port should automatically download and install all of the packages listed in this chapter that you need. One of the packages that you might need is the JadeTeX macro set. - In turn, this macro set requires TeX to be installed. TeX is a large + In turn, this macro set requires &tex; to be installed. &tex; is a large package, and you only need it if you want to produce Postscript or PDF output. To save yourself time and space you must specify whether or not you want JadeTeX (and therefore TeX) installed when you install this port. Either do: &prompt.root; make JADETEX=yes install or &prompt.root; make JADETEX=no install as necessary. Alternatively you may install textproc/docproj-jadetex or textproc/docproj-nojadetex. These slave ports define the JADETEX variable for you, therefore they will install the same suite of applications on your machine. Note that you can produce only HTML or ASCII text output if you do not install JadeTeX. PostScript or PDF output require TeX. Mandatory tools Software These programs are required before you can usefully work with the FreeBSD documentation, and they will allow you to convert the documentation to HTML, plain text, and RTF formats. They are all included in textproc/docproj. SP (textproc/sp) A suite of applications, including a validating SGML parser, and an SGML normaliser. Jade (textproc/jade) A DSSSL implementation. Used for converting marked up documents to other formats, including HTML and TeX. Tidy (www/tidy) An HTML 'pretty printer', used to reformat some of the automatically generated HTML so that it is easier to follow. Links (www/links) A text-mode WWW browser that can also convert HTML files to plain text. peps (graphics/peps) Some of the documentation includes images, some of which are stored as EPS files. These must be converted to PNG before most web browsers will display them. DTDs and Entities These are the DTDs and entity sets used by the FDP. They need to be installed before you can work with any of the documentation. HTML DTD (textproc/html) HTML is the markup language of choice for the World Wide Web, and is used throughout the FreeBSD web site. DocBook DTD (textproc/docbook) DocBook is designed for marking up technical documentation. All the FreeBSD documentation is written in DocBook. ISO 8879 entities (textproc/iso8879) 19 of the ISO 8879:1986 character entity sets used by many DTDs. Includes named mathematical symbols, additional characters in the 'Latin' character set (accents, diacriticals, and so on), and Greek symbols. Stylesheets The stylesheets are used when converting and formatting the documentation for display on screen, printing, and so on. Modular DocBook Stylesheets (textproc/dsssl-docbook-modular) The Modular DocBook Stylesheets are used when converting documentation marked up in DocBook to other formats, such as HTML or RTF. Optional tools You do not need to have any of the following installed. However, you may find it easier to work with the documentation if you do, and they may give you more flexibility in the output formats that can be generated. Software JadeTeX and teTeX (print/jadetex and print/teTeX) Jade and teTeX are used to convert DocBook documents to DVI, Postscript, and PDF formats. The JadeTeX macros are needed in order to do this. If you do not intend to convert your documentation to one of these formats (i.e., HTML, plain text, and RTF are sufficient) then you do not need to install JadeTeX and teTeX. This can be a significant space and time saver, as teTeX is over 30MB in size. If you decide to install JadeTeX and teTeX then you will need to configure teTeX after JadeTeX has been installed. print/jadetex/pkg-message contains detailed instructions explaining what you need to do. Emacs or XEmacs (editors/emacs or editors/xemacs) Both these editors include a special mode for editing documents marked up according to an SGML DTD. This mode includes commands to reduce the amount of typing you need, and help reduce the possibility of errors. You do not need to use them; any text editor can be used to edit marked up documents. You may find they make you more efficient. If anyone has recommendations for other software that is useful when manipulating SGML documents, please let &a.doceng; know, so they can be added to this list.