diff options
| author | Eli Zaretskii | 2006-05-06 12:52:00 +0000 |
|---|---|---|
| committer | Eli Zaretskii | 2006-05-06 12:52:00 +0000 |
| commit | 844040f3f39ce869cb43bf8a26805f7157ad75d2 (patch) | |
| tree | de9b5bd69fa91a5e62abf0d5da820b855bd13ab1 | |
| parent | af330736d14bb0fe3b8121d90bd5bbf92bdd20f8 (diff) | |
| download | emacs-844040f3f39ce869cb43bf8a26805f7157ad75d2.tar.gz emacs-844040f3f39ce869cb43bf8a26805f7157ad75d2.zip | |
(Backup, Version Control, VC Concepts)
(Types of Log File, Advanced C-x v v, Log Buffer, Old Versions)
(Registering, VC Status, VC Undo, Multi-User Branching)
(Comparing Files): Replace inforef to emacs-xtra by conditional xref's,
depending on @iftex/@ifnottex.
(Secondary VC Commands) [ifnottex]: Add menu entries for vc-xtra.texi
subsections.
(VC Undo) [ifnottex]: @include vc1-xtra.texi and @lowersections it.
(Multi-User Branching) [ifnottex]: @include vc2-xtra.texi.
(Reverting) [ifnottex]: @include arevert-xtra.texi.
(Files) [ifnottex]: Add menu entry for Autorevert.
| -rw-r--r-- | man/files.texi | 168 |
1 files changed, 138 insertions, 30 deletions
diff --git a/man/files.texi b/man/files.texi index 60c13783210..de9663471f2 100644 --- a/man/files.texi +++ b/man/files.texi | |||
| @@ -25,6 +25,9 @@ on file directories. | |||
| 25 | * Visiting:: Visiting a file prepares Emacs to edit the file. | 25 | * Visiting:: Visiting a file prepares Emacs to edit the file. |
| 26 | * Saving:: Saving makes your changes permanent. | 26 | * Saving:: Saving makes your changes permanent. |
| 27 | * Reverting:: Reverting cancels all the changes not saved. | 27 | * Reverting:: Reverting cancels all the changes not saved. |
| 28 | @ifnottex | ||
| 29 | * Autorevert:: Auto Reverting non-file buffers. | ||
| 30 | @end ifnottex | ||
| 28 | * Auto Save:: Auto Save periodically protects against loss of data. | 31 | * Auto Save:: Auto Save periodically protects against loss of data. |
| 29 | * File Aliases:: Handling multiple names for one file. | 32 | * File Aliases:: Handling multiple names for one file. |
| 30 | * Version Control:: Version control systems (RCS, CVS and SCCS). | 33 | * Version Control:: Version control systems (RCS, CVS and SCCS). |
| @@ -521,8 +524,14 @@ value is @code{t}, so that Emacs does write backup files. | |||
| 521 | Control}), the variable @code{vc-make-backup-files} determines whether | 524 | Control}), the variable @code{vc-make-backup-files} determines whether |
| 522 | to make backup files. By default it is @code{nil}, since backup files | 525 | to make backup files. By default it is @code{nil}, since backup files |
| 523 | are redundant when you store all the previous versions in a version | 526 | are redundant when you store all the previous versions in a version |
| 524 | control system. @xref{General VC Options,,,emacs-xtra, Specialized | 527 | control system. |
| 525 | Emacs Features}. | 528 | @iftex |
| 529 | @xref{General VC Options,,,emacs-xtra, Specialized Emacs Features}. | ||
| 530 | @end iftex | ||
| 531 | @ifnottex | ||
| 532 | @xref{General VC Options}. | ||
| 533 | @end ifnottex | ||
| 534 | |||
| 526 | 535 | ||
| 527 | At your option, Emacs can keep either a single backup for each file, | 536 | At your option, Emacs can keep either a single backup for each file, |
| 528 | or make a series of numbered backup files for each file that you edit. | 537 | or make a series of numbered backup files for each file that you edit. |
| @@ -976,6 +985,10 @@ modes do not check or revert remote files. | |||
| 976 | @xref{VC Mode Line}, for Auto Revert peculiarities in buffers that | 985 | @xref{VC Mode Line}, for Auto Revert peculiarities in buffers that |
| 977 | visit files under version control. | 986 | visit files under version control. |
| 978 | 987 | ||
| 988 | @ifnottex | ||
| 989 | @include arevert-xtra.texi | ||
| 990 | @end ifnottex | ||
| 991 | |||
| 979 | @node Auto Save | 992 | @node Auto Save |
| 980 | @section Auto-Saving: Protection Against Disasters | 993 | @section Auto-Saving: Protection Against Disasters |
| 981 | @cindex Auto Save mode | 994 | @cindex Auto Save mode |
| @@ -1205,7 +1218,13 @@ RCS or CVS, you can switch to CSSC. | |||
| 1205 | 1218 | ||
| 1206 | VC is enabled by default in Emacs. To disable it, set the | 1219 | VC is enabled by default in Emacs. To disable it, set the |
| 1207 | customizable variable @code{vc-handled-backends} to @code{nil} | 1220 | customizable variable @code{vc-handled-backends} to @code{nil} |
| 1221 | @iftex | ||
| 1208 | (@pxref{Customizing VC,,,emacs-xtra, Specialized Emacs Features}). | 1222 | (@pxref{Customizing VC,,,emacs-xtra, Specialized Emacs Features}). |
| 1223 | @end iftex | ||
| 1224 | @ifnottex | ||
| 1225 | (@pxref{Customizing VC}). | ||
| 1226 | @end ifnottex | ||
| 1227 | |||
| 1209 | 1228 | ||
| 1210 | @menu | 1229 | @menu |
| 1211 | * Introduction to VC:: How version control works in general. | 1230 | * Introduction to VC:: How version control works in general. |
| @@ -1214,6 +1233,12 @@ customizable variable @code{vc-handled-backends} to @code{nil} | |||
| 1214 | * Old Versions:: Examining and comparing old versions. | 1233 | * Old Versions:: Examining and comparing old versions. |
| 1215 | * Secondary VC Commands:: The commands used a little less frequently. | 1234 | * Secondary VC Commands:: The commands used a little less frequently. |
| 1216 | * Branches:: Multiple lines of development. | 1235 | * Branches:: Multiple lines of development. |
| 1236 | @ifnottex | ||
| 1237 | * Remote Repositories:: Efficient access to remote CVS servers. | ||
| 1238 | * Snapshots:: Sets of file versions treated as a unit. | ||
| 1239 | * Miscellaneous VC:: Various other commands and features of VC. | ||
| 1240 | * Customizing VC:: Variables that change VC's behavior. | ||
| 1241 | @end ifnottex | ||
| 1217 | @end menu | 1242 | @end menu |
| 1218 | 1243 | ||
| 1219 | @node Introduction to VC | 1244 | @node Introduction to VC |
| @@ -1351,7 +1376,13 @@ permitted; check-in is still the way to record a new version. | |||
| 1351 | CVS normally allows each user to modify his own copy of the work file | 1376 | CVS normally allows each user to modify his own copy of the work file |
| 1352 | at any time, but requires merging with changes from other users at | 1377 | at any time, but requires merging with changes from other users at |
| 1353 | check-in time. However, CVS can also be set up to require locking. | 1378 | check-in time. However, CVS can also be set up to require locking. |
| 1379 | @iftex | ||
| 1354 | (@pxref{CVS Options,,,emacs-xtra, Specialized Emacs Features}). | 1380 | (@pxref{CVS Options,,,emacs-xtra, Specialized Emacs Features}). |
| 1381 | @end iftex | ||
| 1382 | @ifnottex | ||
| 1383 | (@pxref{CVS Options}). | ||
| 1384 | @end ifnottex | ||
| 1385 | |||
| 1355 | 1386 | ||
| 1356 | @node Types of Log File | 1387 | @node Types of Log File |
| 1357 | @subsubsection Types of Log File | 1388 | @subsubsection Types of Log File |
| @@ -1383,8 +1414,14 @@ for each change just once, then put it into both logs. You can write | |||
| 1383 | the entry in @file{ChangeLog}, then copy it to the log buffer when you | 1414 | the entry in @file{ChangeLog}, then copy it to the log buffer when you |
| 1384 | check in the change. Or you can write the entry in the log buffer | 1415 | check in the change. Or you can write the entry in the log buffer |
| 1385 | while checking in the change, and later use the @kbd{C-x v a} command | 1416 | while checking in the change, and later use the @kbd{C-x v a} command |
| 1386 | to copy it to @file{ChangeLog} (@pxref{Change Logs and | 1417 | to copy it to @file{ChangeLog} |
| 1387 | VC,,,emacs-xtra, Specialized Emacs Features}). | 1418 | @iftex |
| 1419 | (@pxref{Change Logs and VC,,,emacs-xtra, Specialized Emacs Features}). | ||
| 1420 | @end iftex | ||
| 1421 | @ifnottex | ||
| 1422 | (@pxref{Change Logs and VC}). | ||
| 1423 | @end ifnottex | ||
| 1424 | |||
| 1388 | 1425 | ||
| 1389 | @node VC Mode Line | 1426 | @node VC Mode Line |
| 1390 | @subsection Version Control and the Mode Line | 1427 | @subsection Version Control and the Mode Line |
| @@ -1548,8 +1585,15 @@ the repository. | |||
| 1548 | @cindex specific version control system | 1585 | @cindex specific version control system |
| 1549 | Instead of the version number, you can also specify the name of a | 1586 | Instead of the version number, you can also specify the name of a |
| 1550 | version control system. This is useful when one file is being managed | 1587 | version control system. This is useful when one file is being managed |
| 1551 | with two version control systems at the same time (@pxref{Local | 1588 | with two version control systems at the same time |
| 1552 | Version Control,,,emacs-xtra, Specialized Emacs Features}). | 1589 | @iftex |
| 1590 | (@pxref{Local Version Control,,,emacs-xtra, Specialized Emacs | ||
| 1591 | Features}). | ||
| 1592 | @end iftex | ||
| 1593 | @ifnottex | ||
| 1594 | (@pxref{Local Version Control}). | ||
| 1595 | @end ifnottex | ||
| 1596 | |||
| 1553 | @end itemize | 1597 | @end itemize |
| 1554 | 1598 | ||
| 1555 | @node Log Buffer | 1599 | @node Log Buffer |
| @@ -1571,16 +1615,27 @@ control, you can generate the Log Edit text from the ChangeLog using | |||
| 1571 | entries for the file(s) concerned in the top entry in the ChangeLog | 1615 | entries for the file(s) concerned in the top entry in the ChangeLog |
| 1572 | and uses those paragraphs as the log text. This text is only inserted | 1616 | and uses those paragraphs as the log text. This text is only inserted |
| 1573 | if the top entry was made under your user name on the current date. | 1617 | if the top entry was made under your user name on the current date. |
| 1618 | @iftex | ||
| 1574 | @xref{Change Logs and VC,,,emacs-xtra, Specialized Emacs Features}, | 1619 | @xref{Change Logs and VC,,,emacs-xtra, Specialized Emacs Features}, |
| 1620 | @end iftex | ||
| 1621 | @ifnottex | ||
| 1622 | @xref{Change Logs and VC}, | ||
| 1623 | @end ifnottex | ||
| 1575 | for the opposite way of working---generating ChangeLog entries from | 1624 | for the opposite way of working---generating ChangeLog entries from |
| 1576 | the revision control log. | 1625 | the revision control log. |
| 1577 | 1626 | ||
| 1578 | In the @samp{*VC-Log*} buffer, @kbd{C-c C-f} (@kbd{M-x | 1627 | In the @samp{*VC-Log*} buffer, @kbd{C-c C-f} (@kbd{M-x |
| 1579 | log-edit-show-files}) shows the list of files to be committed in case | 1628 | log-edit-show-files}) shows the list of files to be committed in case |
| 1580 | you need to check that. (This can be a list of more than one file if | 1629 | you need to check that. (This can be a list of more than one file if |
| 1581 | you use VC Dired mode or PCL-CVS. @xref{VC Dired Mode,,,emacs-xtra, | 1630 | you use VC Dired mode or PCL-CVS. |
| 1582 | Specialized Emacs Features}, and @ref{Top, , About PCL-CVS, pcl-cvs, | 1631 | @iftex |
| 1583 | PCL-CVS --- The Emacs Front-End to CVS}.) | 1632 | @xref{VC Dired Mode,,,emacs-xtra, Specialized Emacs Features}, |
| 1633 | @end iftex | ||
| 1634 | @ifnottex | ||
| 1635 | @xref{VC Dired Mode}, | ||
| 1636 | @end ifnottex | ||
| 1637 | and @ref{Top, , About PCL-CVS, pcl-cvs, PCL-CVS --- The Emacs | ||
| 1638 | Front-End to CVS}.) | ||
| 1584 | 1639 | ||
| 1585 | When you have finished editing the log message, type @kbd{C-c C-c} to | 1640 | When you have finished editing the log message, type @kbd{C-c C-c} to |
| 1586 | exit the buffer and commit the change. | 1641 | exit the buffer and commit the change. |
| @@ -1648,7 +1703,13 @@ Both forms display the output in a special buffer in another window. | |||
| 1648 | You can specify a checked-in version by its number; an empty input | 1703 | You can specify a checked-in version by its number; an empty input |
| 1649 | specifies the current contents of the work file (which may be different | 1704 | specifies the current contents of the work file (which may be different |
| 1650 | from all the checked-in versions). You can also specify a snapshot name | 1705 | from all the checked-in versions). You can also specify a snapshot name |
| 1651 | (@pxref{Snapshots,,,emacs-xtra, Specialized Emacs Features}) instead of one or both version numbers. | 1706 | @iftex |
| 1707 | (@pxref{Snapshots,,,emacs-xtra, Specialized Emacs Features}) | ||
| 1708 | @end iftex | ||
| 1709 | @ifnottex | ||
| 1710 | (@pxref{Snapshots}) | ||
| 1711 | @end ifnottex | ||
| 1712 | instead of one or both version numbers. | ||
| 1652 | 1713 | ||
| 1653 | If you supply a directory name instead of the name of a registered | 1714 | If you supply a directory name instead of the name of a registered |
| 1654 | file, this command compares the two specified versions of all registered | 1715 | file, this command compares the two specified versions of all registered |
| @@ -1737,6 +1798,10 @@ use once a day. | |||
| 1737 | * Registering:: Putting a file under version control. | 1798 | * Registering:: Putting a file under version control. |
| 1738 | * VC Status:: Viewing the VC status of files. | 1799 | * VC Status:: Viewing the VC status of files. |
| 1739 | * VC Undo:: Canceling changes before or after check-in. | 1800 | * VC Undo:: Canceling changes before or after check-in. |
| 1801 | @ifnottex | ||
| 1802 | * VC Dired Mode:: Listing files managed by version control. | ||
| 1803 | * VC Dired Commands:: Commands to use in a VC Dired buffer. | ||
| 1804 | @end ifnottex | ||
| 1740 | @end menu | 1805 | @end menu |
| 1741 | 1806 | ||
| 1742 | @node Registering | 1807 | @node Registering |
| @@ -1757,8 +1822,13 @@ to use for it. If the file's directory already contains files | |||
| 1757 | registered in a version control system, Emacs uses that system. If | 1822 | registered in a version control system, Emacs uses that system. If |
| 1758 | there is more than one system in use for a directory, Emacs uses the | 1823 | there is more than one system in use for a directory, Emacs uses the |
| 1759 | one that appears first in @code{vc-handled-backends} | 1824 | one that appears first in @code{vc-handled-backends} |
| 1760 | (@pxref{Customizing VC,,,emacs-xtra, Specialized Emacs Features}). On | 1825 | @iftex |
| 1761 | the other hand, if there are no files already registered, Emacs uses | 1826 | (@pxref{Customizing VC,,,emacs-xtra, Specialized Emacs Features}). |
| 1827 | @end iftex | ||
| 1828 | @ifnottex | ||
| 1829 | (@pxref{Customizing VC}). | ||
| 1830 | @end ifnottex | ||
| 1831 | On the other hand, if there are no files already registered, Emacs uses | ||
| 1762 | the first system from @code{vc-handled-backends} that could register | 1832 | the first system from @code{vc-handled-backends} that could register |
| 1763 | the file (for example, you cannot register a file under CVS if its | 1833 | the file (for example, you cannot register a file under CVS if its |
| 1764 | directory is not already part of a CVS tree); with the default value | 1834 | directory is not already part of a CVS tree); with the default value |
| @@ -1818,16 +1888,27 @@ count. | |||
| 1818 | 1888 | ||
| 1819 | @item P | 1889 | @item P |
| 1820 | Move to the log of the previous file, when the logs of multiple files | 1890 | Move to the log of the previous file, when the logs of multiple files |
| 1821 | are in the log buffer (@pxref{VC Dired Mode,,,emacs-xtra, Specialized | 1891 | are in the log buffer |
| 1822 | Emacs Features}). Otherwise, just move to the beginning of the log. A | 1892 | @iftex |
| 1823 | numeric prefix argument is a repeat count, so @kbd{C-u 10 P} would | 1893 | (@pxref{VC Dired Mode,,,emacs-xtra, Specialized Emacs Features}). |
| 1824 | move backward 10 files. | 1894 | @end iftex |
| 1895 | @ifnottex | ||
| 1896 | (@pxref{VC Dired Mode}). | ||
| 1897 | @end ifnottex | ||
| 1898 | Otherwise, just move to the beginning of the log. A numeric prefix | ||
| 1899 | argument is a repeat count, so @kbd{C-u 10 P} would move backward 10 | ||
| 1900 | files. | ||
| 1825 | 1901 | ||
| 1826 | @item N | 1902 | @item N |
| 1827 | Move to the log of the next file, when the logs of multiple files are | 1903 | Move to the log of the next file, when the logs of multiple files are |
| 1828 | in the log buffer (@pxref{VC Dired Mode,,,emacs-xtra, Specialized | 1904 | in the log buffer |
| 1829 | Emacs Features}). It also takes a numeric prefix argument as a repeat | 1905 | @iftex |
| 1830 | count. | 1906 | (@pxref{VC Dired Mode,,,emacs-xtra, Specialized Emacs Features}). |
| 1907 | @end iftex | ||
| 1908 | @ifnottex | ||
| 1909 | (@pxref{VC Dired Mode}). | ||
| 1910 | @end ifnottex | ||
| 1911 | It also takes a numeric prefix argument as a repeat count. | ||
| 1831 | 1912 | ||
| 1832 | @item f | 1913 | @item f |
| 1833 | Visit the revision indicated at the current line, like typing @kbd{C-x | 1914 | Visit the revision indicated at the current line, like typing @kbd{C-x |
| @@ -1881,11 +1962,16 @@ change and then discover a trivial error in it; you can cancel the | |||
| 1881 | erroneous check-in, fix the error, and check the file in again. | 1962 | erroneous check-in, fix the error, and check the file in again. |
| 1882 | 1963 | ||
| 1883 | When @kbd{C-x v c} does not revert the buffer, it unexpands all | 1964 | When @kbd{C-x v c} does not revert the buffer, it unexpands all |
| 1884 | version control headers in the buffer instead (@pxref{Version | 1965 | version control headers in the buffer instead |
| 1885 | Headers,,,emacs-xtra, Specialized Emacs Features}). This is because | 1966 | @iftex |
| 1886 | the buffer no longer corresponds to any existing version. If you | 1967 | (@pxref{Version Headers,,,emacs-xtra, Specialized Emacs Features}). |
| 1887 | check it in again, the check-in process will expand the headers | 1968 | @end iftex |
| 1888 | properly for the new version number. | 1969 | @ifnottex |
| 1970 | (@pxref{Version Headers}). | ||
| 1971 | @end ifnottex | ||
| 1972 | This is because the buffer no longer corresponds to any existing | ||
| 1973 | version. If you check it in again, the check-in process will expand | ||
| 1974 | the headers properly for the new version number. | ||
| 1889 | 1975 | ||
| 1890 | However, it is impossible to unexpand the RCS @samp{@w{$}Log$} header | 1976 | However, it is impossible to unexpand the RCS @samp{@w{$}Log$} header |
| 1891 | automatically. If you use that header feature, you have to unexpand it | 1977 | automatically. If you use that header feature, you have to unexpand it |
| @@ -1897,6 +1983,13 @@ confirmation with @kbd{yes}. Note also that this command is disabled | |||
| 1897 | under CVS, because canceling versions is very dangerous and discouraged | 1983 | under CVS, because canceling versions is very dangerous and discouraged |
| 1898 | with CVS. | 1984 | with CVS. |
| 1899 | 1985 | ||
| 1986 | @ifnottex | ||
| 1987 | @c vc1-xtra.texi needs extra level of lowering. | ||
| 1988 | @lowersections | ||
| 1989 | @include vc1-xtra.texi | ||
| 1990 | @raisesections | ||
| 1991 | @end ifnottex | ||
| 1992 | |||
| 1900 | @node Branches | 1993 | @node Branches |
| 1901 | @subsection Multiple Branches of a File | 1994 | @subsection Multiple Branches of a File |
| 1902 | @cindex branch (version control) | 1995 | @cindex branch (version control) |
| @@ -2075,10 +2168,15 @@ own choice of selected versions, but all share the same common RCS | |||
| 2075 | records. | 2168 | records. |
| 2076 | 2169 | ||
| 2077 | This technique works reliably and automatically, provided that the | 2170 | This technique works reliably and automatically, provided that the |
| 2078 | source files contain RCS version headers (@pxref{Version | 2171 | source files contain RCS version headers |
| 2079 | Headers,,,emacs-xtra, Specialized Emacs Features}). The headers enable | 2172 | @iftex |
| 2080 | Emacs to be sure, at all times, which version number is present in the | 2173 | (@pxref{Version Headers,,,emacs-xtra, Specialized Emacs Features}). |
| 2081 | work file. | 2174 | @end iftex |
| 2175 | @ifnottex | ||
| 2176 | (@pxref{Version Headers}). | ||
| 2177 | @end ifnottex | ||
| 2178 | The headers enable Emacs to be sure, at all times, which version | ||
| 2179 | number is present in the work file. | ||
| 2082 | 2180 | ||
| 2083 | If the files do not have version headers, you must instead tell Emacs | 2181 | If the files do not have version headers, you must instead tell Emacs |
| 2084 | explicitly in each session which branch you are working on. To do this, | 2182 | explicitly in each session which branch you are working on. To do this, |
| @@ -2086,6 +2184,10 @@ first find the file, then type @kbd{C-u C-x v v} and specify the correct | |||
| 2086 | branch number. This ensures that Emacs knows which branch it is using | 2184 | branch number. This ensures that Emacs knows which branch it is using |
| 2087 | during this particular editing session. | 2185 | during this particular editing session. |
| 2088 | 2186 | ||
| 2187 | @ifnottex | ||
| 2188 | @include vc2-xtra.texi | ||
| 2189 | @end ifnottex | ||
| 2190 | |||
| 2089 | @node Directories | 2191 | @node Directories |
| 2090 | @section File Directories | 2192 | @section File Directories |
| 2091 | 2193 | ||
| @@ -2208,8 +2310,14 @@ typically the result of a failed merge from a version control system | |||
| 2208 | mode provides commands to resolve conflicts by selecting specific | 2310 | mode provides commands to resolve conflicts by selecting specific |
| 2209 | changes. | 2311 | changes. |
| 2210 | 2312 | ||
| 2211 | @inforef{Emerge,, emacs-xtra} for the Emerge facility, which | 2313 | @iftex |
| 2212 | provides a powerful interface for merging files. | 2314 | @xref{Emerge,,, emacs-xtra}, |
| 2315 | @end iftex | ||
| 2316 | @ifnottex | ||
| 2317 | @xref{Emerge}, | ||
| 2318 | @end ifnottex | ||
| 2319 | for the Emerge facility, which provides a powerful interface for | ||
| 2320 | merging files. | ||
| 2213 | 2321 | ||
| 2214 | @node Diff Mode | 2322 | @node Diff Mode |
| 2215 | @section Diff Mode | 2323 | @section Diff Mode |