The translation is temporarily closed for contributions due to maintenance, please come back later.

Source string Read only

(itstool) path: sect1/para
Context English State
These applications are not required, but can make working on the documentation easier or add capabilities.
<application>Vim</application> (<package>editors/vim</package>)
A popular editor for working with <acronym>XML</acronym> and derived documents, like DocBook <acronym>XML</acronym>.
<application>Emacs</application> (<package>editors/emacs</package>)
Both of these editors include a special mode for editing documents marked up according to an <acronym>XML</acronym> <acronym>DTD</acronym>. This mode includes commands to reduce the amount of typing needed, and help reduce the possibility of errors.
The Working Copy
The <emphasis>working copy</emphasis> is a copy of the FreeBSD repository documentation tree downloaded onto the local computer. Changes are made to the local working copy, tested, and then submitted as patches to be committed to the main repository.
A full copy of the documentation tree can occupy 700 megabytes of disk space. Allow for a full gigabyte of space to have room for temporary files and test versions of various output formats.
<link xlink:href="@@URL_RELPREFIX@@/doc/en_US.ISO8859-1/books/handbook/svn.html"><application>Subversion</application></link> is used to manage the FreeBSD documentation files. It is obtained by installing the <application>Subversion</application> package:
<prompt>#</prompt> <userinput>pkg install subversion</userinput>
Documentation and Manual Pages
FreeBSD documentation is not just books and articles. Manual pages for all the commands and configuration files are also part of the documentation, and part of the <acronym>FDP</acronym>'s territory. Two repositories are involved: <literal>doc</literal> for the books and articles, and <literal>base</literal> for the operating system and manual pages. To edit manual pages, the <literal>base</literal> repository must be checked out separately.
Repositories may contain multiple versions of documentation and source code. New modifications are almost always made only to the latest version, called <literal>head</literal>.
Choosing a Directory
FreeBSD documentation is traditionally stored in <filename>/usr/doc/</filename>, and system source code with manual pages in <filename>/usr/src/</filename>. These directory trees are relocatable, and users may want to put the working copies in other locations to avoid interfering with existing information in the main directories. The examples that follow use <filename>~/doc</filename> and <filename>~/src</filename>, both subdirectories of the user's home directory.
Checking Out a Copy
A download of a working copy from the repository is called a <emphasis>checkout</emphasis>, and done with <command>svn checkout</command>. This example checks out a copy of the latest version (<literal>head</literal>) of the main documentation tree:
A checkout of the source code to work on manual pages is very similar:
<prompt>%</prompt> <userinput>svn checkout <replaceable>~/src</replaceable></userinput>
Updating a Working Copy
The documents and files in the FreeBSD repository change daily. People modify files and commit changes frequently. Even a short time after an initial checkout, there will already be differences between the local working copy and the main FreeBSD repository. To update the local version with the changes that have been made to the main repository, use <command>svn update</command> on the directory containing the local working copy:
<prompt>%</prompt> <userinput>svn update <replaceable>~/doc</replaceable></userinput>
Get in the protective habit of using <command>svn update</command> before editing document files. Someone else may have edited that file very recently, and the local working copy will not include the latest changes until it has been updated. Editing the newest version of a file is much easier than trying to combine an older, edited local file with the newer version from the repository.
Reverting Changes
Sometimes it turns out that changes were not necessary after all, or the writer just wants to start over. Files can be <quote>reset</quote> to their unchanged form with <command>svn revert</command>. For example, to erase the edits made to <filename>chapter.xml</filename> and reset it to unmodified form:
<prompt>%</prompt> <userinput>svn revert chapter.xml</userinput>
Making a Diff
After edits to a file or group of files are completed, the differences between the local working copy and the version on the FreeBSD repository must be collected into a single file for submission. These <emphasis>diff</emphasis> files are produced by redirecting the output of <command>svn diff</command> into a file:
<prompt>%</prompt> <userinput>cd <replaceable>~/doc</replaceable></userinput>
<prompt>%</prompt> <userinput>svn diff &gt; <replaceable>doc-fix-spelling.diff</replaceable></userinput>
Give the file a meaningful name that identifies the contents. The example above is for spelling fixes to the whole documentation tree.


No matching activity found.

Browse all component changes

Source information

Source string comment
(itstool) path: sect1/para
Source string location
String age
a year ago
Source string age
a year ago
Translation file
books/fdp-primer.pot, string 128