(outline-1, outline-2, outline-3, outline-4)
[bpt/emacs.git] / man / pcl-cvs.texi
CommitLineData
e9f75053
SM
1\input texinfo @c -*-texinfo-*-
2
28665d46 3@c "@(#)$Name: $:$Id: pcl-cvs.texi,v 1.15 2002/04/09 18:41:56 monnier Exp $"
e9f75053
SM
4
5@c Documentation for the GNU Emacs CVS mode.
115209ba 6@c Copyright (C) 1991,92,93,94,95,96,97,98,99,2000, 2001 Free Software Foundation, Inc.
e9f75053
SM
7
8@c This file is part of GNU Emacs
9
10@c GNU Emacs is free software; you can redistribute it and/or modify
11@c it under the terms of the GNU General Public License as published by
12@c the Free Software Foundation; either version 2 of the License,
13@c or (at your option) any later version.
14
15@c GNU Emacs is distributed in the hope that it will be useful,
16@c but WITHOUT ANY WARRANTY; without even the implied warranty of
17@c MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18@c GNU General Public License for more details.
19
20@c You should have received a copy of the GNU General Public License
21@c along with pcl-cvs; see the file COPYING. If not, write to
22@c the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
23
24@c %**start of header
25@setfilename ../info/pcl-cvs
c3114036 26@settitle PCL-CVS --- Emacs Front-End to CVS
e9f75053
SM
27@c %**end of header
28
89cda0c5
SM
29@c
30
1b4368fe 31@dircategory Emacs
e9f75053 32@direntry
1b4368fe 33* PCL-CVS: (pcl-cvs). Emacs front-end to CVS.
e9f75053
SM
34@end direntry
35@setchapternewpage on
89cda0c5 36
e9f75053 37@ifinfo
e7cff550 38Copyright @copyright{} 1991,92,93,94,95,96,97,98,99,2000 Free Software Foundation, Inc.
e9f75053 39
42664031
SM
40Permission is granted to copy, distribute and/or modify this document
41under the terms of the GNU Free Documentation License, Version 1.1 or
42any later version published by the Free Software Foundation; with the
43Invariant Sections being ``The GNU Manifesto'', ``Distribution'' and
44``GNU GENERAL PUBLIC LICENSE'', with the Front-Cover texts being ``A GNU
45Manual'', and with the Back-Cover Texts as in (a) below. A copy of the
46license is included in the section entitled ``GNU Free Documentation
47License'' in the Emacs manual.
48
49This document is part of a collection distributed under the GNU Free
50Documentation License. If you want to distribute this document
51separately from the collection, you can do so by adding a copy of the
52license to the document, as described in section 6 of the license.
53
54(a) The FSF's Back-Cover Text is: ``You have freedom to copy and modify
55this GNU Manual, like GNU software. Copies published by the Free
56Software Foundation raise funds for GNU development.''
e9f75053
SM
57@end ifinfo
58
11dac025 59@syncodeindex vr fn
e9f75053
SM
60@c The titlepage section does not appear in the Info file.
61@titlepage
62@sp 4
63@c The title is printed in a large font.
64@center @titlefont{User's Guide}
65@sp
66@center @titlefont{to}
67@sp
bdb6b1e1 68@center @titlefont{PCL-CVS --- The Emacs Front-End to CVS}
59869d21 69@ignore
e9f75053
SM
70@sp 2
71@center release 2.9
72@c -release-
59869d21 73@end ignore
e9f75053
SM
74@sp 3
75@center Per Cederqvist
76@center Stefan Monnier
77@c -date-
78
79@c The following two commands start the copyright page
80@c for the printed manual. This will not appear in the Info file.
81@page
82@vskip 0pt plus 1filll
e7cff550 83Copyright @copyright{} 1991,92,93,94,95,96,97,98,99,2000 Free Software Foundation, Inc.
e9f75053 84
42664031
SM
85Permission is granted to copy, distribute and/or modify this document
86under the terms of the GNU Free Documentation License, Version 1.1 or
87any later version published by the Free Software Foundation; with the
88Invariant Sections being ``The GNU Manifesto'', ``Distribution'' and
89``GNU GENERAL PUBLIC LICENSE'', with the Front-Cover texts being ``A GNU
90Manual'', and with the Back-Cover Texts as in (a) below. A copy of the
91license is included in the section entitled ``GNU Free Documentation
92License'' in the Emacs manual.
93
94This document is part of a collection distributed under the GNU Free
95Documentation License. If you want to distribute this document
96separately from the collection, you can do so by adding a copy of the
97license to the document, as described in section 6 of the license.
98
99(a) The FSF's Back-Cover Text is: ``You have freedom to copy and modify
100this GNU Manual, like GNU software. Copies published by the Free
101Software Foundation raise funds for GNU development.''
e9f75053
SM
102@end titlepage
103
104@c ================================================================
105@c The real text starts here
106@c ================================================================
107
108@node Top, About PCL-CVS, (dir), (dir)
109@ifinfo
110@top PCL-CVS
111
11dac025 112This manual describes PCL-CVS, the GNU Emacs front-end to CVS. It
59869d21 113is nowhere near complete, so you are advised to use @kbd{M-x
11dac025 114customize-group RET pcl-cvs @key{RET}} and to look at the documentation strings
59869d21
SM
115of the various commands and major modes for further information.
116@c This manual is updated to release 2.5 of PCL-CVS.
e9f75053
SM
117@end ifinfo
118
119@menu
11dac025 120* About PCL-CVS:: Installation, credits, history, @dots{}
e9f75053
SM
121
122* Getting started:: An introduction with a walk-through example.
123* Buffer contents:: An explanation of the buffer contents.
124* Selected files:: To which files are commands applied.
125* Commands:: All commands, grouped by type.
126
115209ba
DL
127* Log Edit Mode:: Major mode to edit log messages.
128* Log View Mode:: Major mode to browse log changes.
e7610308 129@c * CVS Status Mode:: Major mode to view CVS' status output.
e9f75053
SM
130* Customization:: How you can tailor PCL-CVS to suit your needs.
131* Bugs:: Bugs (known and unknown).
132
133* Function and Variable Index:: List of functions and variables.
134* Concept Index:: List of concepts.
135* Key Index:: List of keystrokes.
136
137@detailmenu
138 --- The Detailed Node Listing ---
139
140About PCL-CVS
141
142* Contributors:: Contributors to PCL-CVS.
143* Installation::
144
145Commands
146
147* Entering PCL-CVS:: Commands to invoke PCL-CVS
148* Setting flags:: Setting flags for CVS commands
149* Updating the buffer::
150* Movement commands:: How to move up and down in the buffer
151* Marking files:: How to mark files that other commands
152 will later operate on.
153* Committing changes:: Checking in your modifications to the
154 CVS repository.
155* Editing files:: Loading files into Emacs.
156* Getting info about files:: Display the log and status of files.
157* Adding and removing files:: Adding and removing files
158* Undoing changes:: Undoing changes
159* Removing handled entries:: Uninteresting lines can easily be removed.
160* Ignoring files:: Telling CVS to ignore generated files.
161* Viewing differences:: Commands to @samp{diff} different versions.
162* Invoking Ediff:: Running @samp{ediff} from @samp{*cvs*} buffer.
163* Updating files:: Updating files that Need-update.
164* Tagging files:: Tagging files.
165* Miscellaneous commands:: Miscellaneous commands.
166
167Customization
168
169* Customizing Faces::
170
171@end detailmenu
172@end menu
173
174@node About PCL-CVS, Getting started, Top, Top
175@chapter About PCL-CVS
176@cindex About PCL-CVS
177
178PCL-CVS is a front-end to CVS versions 1.9 and later.
179It concisely shows the present status of a checked out module in an
180Emacs buffer and provides single-key access to the most frequently used CVS
181commands.
182For Emacs users accustomed to VC, PCL-CVS can be thought of as a replacement
11dac025
EZ
183for VC-dired (@pxref{VC Dired Mode, , Dired under VC, emacs, The GNU
184Emacs Manual}) specifically designed for CVS.
e9f75053
SM
185
186PCL-CVS was originally written many years ago by Per Cederqvist who
187proudly maintained it until January 1996, at which point he released the
188beta version 2.0b2 and passed on the maintainership to Greg A Woods.
11dac025 189Development stayed mostly dormant for a few years during which
e9f75053 190version 2.0 never seemed to be able to leave the ``beta'' stage while a
59869d21 191separate XEmacs version was slowly splitting away. In late 1998,
e9f75053 192Stefan Monnier picked up development again, adding some major new
11dac025 193functionality and taking over the maintenance.
e9f75053 194
11dac025 195As of Emacs 21, PCL-CVS is part of the standard Emacs distribution.
e9f75053
SM
196
197@menu
198* Contributors:: Contributors to PCL-CVS.
199* Installation::
200@end menu
201
202@node Contributors, Installation, About PCL-CVS, About PCL-CVS
203@section Contributors to PCL-CVS
204@cindex Contributors
205@cindex Authors
206
207Contributions to the package are welcome. I have limited time to work
208on this project, but I will gladly add any code that you contribute to
209me to this package (@pxref{Bugs}).
210
211The following persons have made contributions to PCL-CVS.
212
213@itemize @bullet
214@item
215Brian Berliner wrote CVS, together with some other contributors.
216Without his work on CVS this package would be useless@dots{}
217
218@item
219Per Cederqvist wrote most of the otherwise unattributed functions in
11dac025 220PCL-CVS as well as all the documentation.
e9f75053
SM
221
222@item
11dac025 223@email{inge@@lysator.liu.se, Inge Wallin} wrote the skeleton of
e9f75053
SM
224@file{pcl-cvs.texi}, and gave useful comments on it. He also wrote
225the files @file{elib-node.el} and @file{compile-all.el}. The file
226@file{cookie.el} was inspired by Inge.@refill
227
228@item
11dac025 229@email{linus@@lysator.liu.se, Linus Tolke} contributed useful comments
e9f75053
SM
230on both the functionality and the documentation.@refill
231
232@item
11dac025 233@email{jwz@@jwz.com, Jamie Zawinski} contributed
e9f75053
SM
234@file{pcl-cvs-lucid.el}, which was later renamed to
235@file{pcl-cvs-xemacs.el}.@refill
236
237@item
28665d46 238Leif Lonnblad contributed RCVS support (since superseded by the new
11dac025 239remote CVS support).
e9f75053
SM
240
241@item
11dac025
EZ
242@email{jimb@@cyclic.com, Jim Blandy} contributed hooks to automatically
243guess CVS log entries from @file{ChangeLog} contents, and initial support of
244the new Cygnus / Cyclic remote CVS, as well as various sundry bug fixes
e9f75053
SM
245and cleanups.
246
247@item
11dac025
EZ
248@email{kingdon@@cyclic.com, Jim Kingdon} contributed lots of fixes to
249the build and installation procedure.
e9f75053
SM
250
251@item
11dac025
EZ
252@email{woods@@weird.com, Greg A.@: Woods} contributed code to implement
253the use of per-file diff buffers, and vendor join diffs with emerge and
254ediff, as well as various and sundry bug fixes and cleanups.
e9f75053
SM
255
256@item
11dac025
EZ
257@email{greg.klanderman@@alum.mit.edu, Greg Klanderman} implemented
258toggling of marked files, setting of CVS command flags via prefix
259arguments, updated the XEmacs support, updated the manual, and fixed
e9f75053
SM
260numerous bugs.
261
262@item
11dac025 263@email{monnier@@cs.yale.edu, Stefan Monnier} added a slew of other
e9f75053
SM
264features and introduced even more new bugs. If there's any bug left,
265you can be sure it's his.
266
267@item
11dac025
EZ
268@c wordy to avoid an underfull hbox
269@email{masata-y@@is.aist-nara.ac.jp, Masatake YAMATO} made a gracious
270contribution of his cvstree code to display a tree of tags which was later
271superseded by the new @code{cvs-status-mode}.
e9f75053
SM
272@end itemize
273
274Apart from these, a lot of people have sent us suggestions, ideas,
275requests, bug reports and encouragement. Thanks a lot! Without you
276there would be no new releases of PCL-CVS.
277
278
279@node Installation, , Contributors, About PCL-CVS
280@section Installation
281@cindex Installation
282
11dac025
EZ
283As mentioned above, PCL-CVS comes bundled with Emacs version 21.1 and
284later. If you're using Emacs 20, you can download an older version of
285PCL-CVS from @uref{ftp://flint.cs.yale.edu/pub/monnier/pcl-cvs}. That
286version also works on XEmacs.
e9f75053
SM
287
288If you are running XEmacs 21.0 or later, PCL-CVS is available in
289pre-compiled package form. Please refer to the XEmacs manual for
290instructions regarding package selection and installation. Currently,
11dac025
EZ
291that PCL-CVS package also requires you to have installed the
292@file{xemacs-base}, @file{elib}, and @file{dired} packages.
e9f75053
SM
293
294If you have @TeX{} installed at your site, you can make a typeset manual
295from @file{pcl-cvs.texi}.
296
297@enumerate
298@item
11dac025
EZ
299If PCL-CVS came with the Emacs distribution, type @kbd{make pcl-cvs.dvi}
300in the @file{man} subdirectory of the Emacs source tree.
301@item
302Alternatively, run @TeX{} by typing @kbd{texi2dvi pcl-cvs.texi}.
e9f75053
SM
303@item
304Convert the resulting device independent file @file{pcl-cvs.dvi} to a
305form which your printer can output and print it. If you have a
11dac025 306PostScript printer, there is a program, @code{dvi2ps}, which does. There
e9f75053
SM
307is also a program which comes together with @TeX{}, @code{dvips}, which
308you can use.
309@end enumerate
310
311
312@node Getting started, Buffer contents, About PCL-CVS, Top
313@chapter Getting started
314@cindex Introduction
315@cindex Example run
11dac025 316@cindex Sample session
e9f75053
SM
317
318This document assumes that you know what CVS is, and that you at least
11dac025
EZ
319know the fundamental concepts of CVS. If that is not the case, you
320should read the CVS documentation. Type @kbd{info -f cvs} or @kbd{man
321cvs}.
e9f75053
SM
322
323PCL-CVS is only useful once you have checked out a module. So before
11dac025 324you invoke it, you must have a copy of a module somewhere in the file
e9f75053
SM
325system.
326
11dac025
EZ
327You can invoke PCL-CVS by typing @kbd{M-x cvs-examine @key{RET}}.
328You can also invoke it via the menu bar, under @samp{Tools}.
329Or, if you prefer, you can also invoke PCL-CVS by simply visiting the
e9f75053 330CVS administrative subdirectory of your module, with a prefix argument.
11dac025
EZ
331For example, to invoke PCL-CVS in a separate frame, type @kbd{C-u C-x 5
332f ~/my/project/CVS @key{RET}}.
e9f75053
SM
333
334The function @code{cvs-examine} will ask for a directory. The command
335@samp{cvs -n update} will be run in that directory. (It should contain
336files that have been checked out from a CVS archive.) The output from
337@code{cvs} will be parsed and presented in a table in a buffer called
338@samp{*cvs*}. It might look something like this:
339
340@example
341Repository : /usr/CVSroot
342Module : test
343Working dir: /users/ceder/FOO/test
344
345
346In directory .:
347 Need-Update bar
348 Need-Update file.txt
349 Modified namechange
350 Need-Update newer
351In directory sub:
352 Modified ChangeLog
353
354--------------------- End ---------------------
355-- last cmd: cvs -f -z6 -n update -d -P --
356@end example
357
358In this example, your repository is in @file{/usr/CVSroot} and CVS has
359been run in the directory @file{/users/ceder/FOO/test}. The three files
360(@file{bar}, @file{file.txt} and
361@file{newer}) that are marked with @samp{Need-Update} have been changed
362by someone else in the CVS repository. Two files (@file{namechange}
363and @file{sub/ChangeLog}) have been modified locally, and need to be
364checked in.
365
366You can move the cursor up and down in the buffer with @kbd{C-n} and
367@kbd{C-p} or @kbd{n} and @kbd{p}. If you press @kbd{c} on one of the
11dac025 368@samp{Modified} files, that file will be checked in to the CVS
e9f75053
SM
369repository. @xref{Committing changes}. You can also press @kbd{O} to
370update any of the files that are marked @samp{Need-Update}. You can
11dac025 371also run @kbd{M-x cvs-update @key{RET}} (bound to @kbd{M-u} in the
e9f75053
SM
372@samp{*cvs*} buffer) to update all the files.@refill
373
374You can then press @kbd{=} to easily get a @samp{diff} between your
11dac025 375modified file and the base version that you started from, or you can
e9f75053
SM
376press @kbd{l} to get the output from @samp{cvs log}. Many more such
377commands are available simply by pressing a key (@pxref{Getting info
378about files}).
379
380@node Buffer contents, Selected files, Getting started, Top
381@chapter Buffer contents
382@cindex Buffer contents
11dac025 383@cindex @code{*cvs*} buffer contents
e9f75053
SM
384
385The display contains several columns, some of which are optional.
11dac025 386These columns are, from left to right:
e9f75053
SM
387
388@itemize @bullet
389
390@item
391Optionally, the head revision of the file. This is the latest version
392found in the repository. It might also contain (instead of the head
393revision) a sub status which typically gives further information about
394how we got to the current state, for example @samp{patched},
11dac025 395@samp{merged}, @dots{}
e9f75053
SM
396
397@item
398An asterisk when the file is @dfn{marked} (@pxref{Selected
399files}).@refill
400
401@item
11dac025 402The actual status of the file wrt the repository. See below.
e9f75053
SM
403
404@item
405Optionally, the base revision of the file. This is the version
406which the copy in your working directory is based upon.
407
408@item
409The file name.
410
411@end itemize
412
413The @samp{file status} field can have the following values:
414
415@table @samp
e9f75053
SM
416@item Modified
417The file is modified in your working directory, and there was no
418modification to the same file in the repository. This status can have
419the following substatus:
420
421@table @samp
e9f75053
SM
422@item merged
423The file was modified in your working directory, and there were
424modifications in the repository as well, but they were merged
425successfully, without conflict, in your working directory.@refill
e9f75053
SM
426@end table
427
428@item Conflict
429A conflict was detected while trying to merge your changes to @var{file}
430with changes from the repository. @var{file} (the copy in your
11dac025 431working directory) is now the output of the @code{rcsmerge} command on
e9f75053
SM
432the two versions; an unmodified copy of your file is also in your
433working directory, with the name @file{.#@var{file}.@var{version}},
434where @var{version} is the RCS revision that your modified file started
435from. @xref{Viewing differences}, for more details.@refill
436
437A conflict can also come from a disagreement on the existence of the file
438rather than on its content. This case is indicated by the following
439possible substatus:
440
441@table @samp
e9f75053
SM
442@item removed
443The file is locally removed but a new revision has been committed to
444the repository by someone else.
445
446@item added
447The file is locally added and has also been added to the repository
448by someone else.
449
450@item modified
451The file is locally modified but someone else has removed it from the
452repository.
e9f75053
SM
453@end table
454
455@item Added
456The file has been added by you, but it still needs to be checked in to
457the repository.@refill
458
459@item Removed
460The file has been removed by you, but it still needs to be checked in to
461the repository. You can resurrect it by typing @kbd{a} (@pxref{Adding
462and removing files}).@refill
463
464@item Unknown
465A file that was detected in your directory, but that neither appears in
466the repository, nor is present on the list of files that CVS should
467ignore.@refill
468
469@item Up-to-date
470The file is up to date with respect to the version in the repository.
471This status can have a substatus of:
472
473@table @samp
e9f75053
SM
474@item added
475You have just added the file to the repository.@refill
476
477@item updated
478The file was brought up to date with respect to the repository. This is
479done for any file that exists in the repository but not in your source,
480and for files that you haven't changed but are not the most recent
481versions available in the repository.@refill
482
483@item patched
484The file was brought up to date with respect to the remote repository by
485way of fetching and applying a patch to the file in your source. This
486is equivalent to @samp{updated} except that CVS decided to use a hopefully
487more efficient method.@refill
488
489@item committed
490You just committed the file.@refill
e9f75053
SM
491@end table
492
493@item Need-Update
494Either a newer version than the one in your source is available in the
495repository and you have not modified your checked out version, or the
496file exists in the repository but not in your source. Use
497@samp{cvs-mode-update} bound to @kbd{O} to update the file.@refill
498
499@item Need-Merge
500You have modified the checked out version of the file, and a newer
501version is available in the repository. A merge will take place when
502you run a @samp{cvs-update}.
503
504@item Missing
505The file has been unexpectedly removed from your working directory
506although it has not been @samp{cvs remove}d.
e9f75053
SM
507@end table
508
509@node Selected files, Commands, Buffer contents, Top
510@chapter Selected files
511@cindex Selected files
512@cindex Marked files
513@cindex File selection
514@cindex Active files
515@cindex Applicable
516
517Many of the commands work on the current set of @dfn{selected} files
518which can be either the set of marked files (if any file is marked and
519marks are no ignored) or whichever file or directory the cursor is on.
520
521If a directory is selected but the command cannot be applied to a
522directory, then it will be applied to the set of files under this
523directory which are in the @samp{*cvs*} buffer.
524
11dac025
EZ
525@findex cvs-mode-force-command
526@findex cvs-allow-dir-commit
e9f75053
SM
527Furthermore, each command only operates on a subset of the selected
528files, depending on whether or not the command is @dfn{applicable} to
529each file (based on the file's status). For example,
530@code{cvs-mode-commit} is not applicable to a file whose status is
531@samp{Need-Update}. If it should happen that PCL-CVS guesses the
532applicability wrong, you can override it with the special prefix
533@code{cvs-mode-force-command} normally bound to @kbd{M-f} (and file a
534bug report). The applicability rule can be slightly changed with
535@code{cvs-allow-dir-commit} and @code{cvs-force-dir-tag}.
536
537By default, marks are always in effect (you may change this, however, by
538setting the variable @code{cvs-default-ignore-marks}) except for the
539commands that @samp{tag} or @samp{diff} a file (which can be changed
540with the variable @code{cvs-invert-ignore-marks}).
541
542In addition, you may use the special prefix @code{cvs-mode-toggle-marks}
543normally bound to @key{T} to toggle the use of marks for the following
544command.
545
546This scheme might seem a little complicated, but once one gets used to
547it, it is quite powerful.
548
11dac025 549For commands to mark and unmark files, see @ref{Marking files}.
e9f75053 550
115209ba 551@node Commands, Log Edit Mode, Selected files, Top
e9f75053
SM
552@chapter Commands
553
554@iftex
555This chapter describes all the commands that you can use in PCL-CVS.
556@end iftex
11dac025 557@ifnottex
e9f75053
SM
558The nodes in this menu contains explanations about all the commands that
559you can use in PCL-CVS. They are grouped together by type.
11dac025 560@end ifnottex
e9f75053
SM
561
562@menu
563* Entering PCL-CVS:: Commands to invoke PCL-CVS
564* Setting flags:: Setting flags for CVS commands
565* Updating the buffer::
566* Movement commands:: How to move up and down in the buffer
567* Marking files:: How to mark files that other commands
568 will later operate on.
569* Committing changes:: Checking in your modifications to the
570 CVS repository.
571* Editing files:: Loading files into Emacs.
572* Getting info about files:: Display the log and status of files.
573* Adding and removing files:: Adding and removing files
574* Undoing changes:: Undoing changes
575* Removing handled entries:: Uninteresting lines can easily be removed.
576* Ignoring files:: Telling CVS to ignore generated files.
577* Viewing differences:: Commands to @samp{diff} different versions.
578* Invoking Ediff:: Running @samp{ediff} from @samp{*cvs*} buffer.
579* Updating files:: Updating files that Need-update.
580* Tagging files:: Tagging files.
581* Miscellaneous commands:: Miscellaneous commands.
582@end menu
583
584
585@node Entering PCL-CVS, Setting flags, Commands, Commands
586@section Entering PCL-CVS
587@findex cvs-update
588@findex cvs-examine
589@findex cvs-status
590@findex cvs-checkout
42664031
SM
591@findex cvs-quickdir
592@cindex Creating the *cvs* buffer
e9f75053
SM
593
594Most commands in PCL-CVS require that you have a @samp{*cvs*}
595buffer. The commands that you use to get one are listed below.
596For each, a @samp{cvs} process will be run, the output will be parsed by
597PCL-CVS, and the result will be printed in the @samp{*cvs*} buffer (see
11dac025 598@ref{Buffer contents}, for a description of the buffer's contents).
e9f75053
SM
599
600@table @kbd
e9f75053
SM
601@item M-x cvs-update
602Run a @samp{cvs update} command. You will be asked for the directory
42664031 603in which the @samp{cvs update} will be run.
e9f75053
SM
604
605@item M-x cvs-examine
606Run a @samp{cvs -n update} command. This is identical to the previous
607command, except that it will only check what needs to be done but will
608not change anything. You will be asked for the directory in
42664031 609which the @samp{cvs -n update} will be run.
e9f75053
SM
610
611@item M-x cvs-status
612Run a @samp{cvs status} command. You will be asked for the directory
42664031 613in which the @samp{cvs status} will be run.
e9f75053
SM
614
615@item M-x cvs-checkout
616Run a @samp{cvs checkout} command. You will be asked for the directory
617in which the @samp{cvs update} will be run and the module to be checked
42664031 618out.
e9f75053
SM
619
620@item M-x cvs-quickdir
621Populate the @samp{*cvs*} buffer by just looking at the @file{CVS/Entries}
622files. This is very much like @code{cvs-examine} except that it does
11dac025 623not access the CVS repository, which is a major advantage when the
e9f75053
SM
624repository is far away. But of course, it will not be able to detect
625when a file needs to be updated or merged.
e9f75053
SM
626@end table
627
11dac025
EZ
628@findex cvs-dired-action
629@findex cvs-dired-use-hook
42664031 630The first four of
11dac025
EZ
631those commands are also reachable from the menu bar
632under @samp{Tools->PCL-CVS}. Finally, an alternative way is to visit
42664031 633the CVS administrative subdirectory in your work area with a simple
11dac025
EZ
634prefix argument. For example @kbd{C-u C-x C-f ~/my/work/CVS @key{RET}}. This
635by default runs @code{cvs-quickdir} but the specific behavior can be
e9f75053
SM
636changed with @code{cvs-dired-action} and @code{cvs-dired-use-hook}.
637
638By default, the commands above will descend recursively into
639subdirectories. You can avoid that behavior by including @samp{-l} in
640the flags for the command. These flags can be set by giving a prefix
641argument to the command (e.g., by typing
11dac025 642@kbd{C-u M-x cvs-update @key{RET} -l @key{RET}}).
e9f75053
SM
643
644
645@node Setting flags, Updating the buffer, Entering PCL-CVS, Commands
646@section Setting flags for CVS commands
11dac025
EZ
647@cindex Optional switches to CVS
648@cindex Command-line options to CVS
e9f75053
SM
649
650This section describes the convention used by nearly all PCL-CVS
651commands for setting optional flags sent to CVS. A single @kbd{C-u}
652prefix argument is used to cause the command to prompt for flags to be
653used for the current invocation of the command only. Two @kbd{C-u} prefix
654arguments are used to prompt for flags which will be set permanently, for the
655current invocation and all that follow, until the flags are changed, or
656unless temporary flags are set which override them.
657
658Perhaps an example or two is in order. Say you are about to add a
659binary file to the repository, and want to specify the flags @samp{-kb}
cd37168e
SM
660to @samp{cvs add}. You can type @kbd{C-u a -kb @key{RET}},
661and the file will be added. Subsequent @samp{cvs add}
11dac025 662commands will use the previously prevailing flags.
e9f75053
SM
663
664As a second example, say you are about to perform a diff and want to see
665the result in unified diff format, i.e. you'd like to pass the flag
666@samp{-u} to both @samp{cvs diff} and @samp{diff}. You'd also like all
11dac025 667subsequent diffs to use this flag. You can type @kbd{C-u C-u = -u @key{RET}}
e9f75053
SM
668and the diff will be performed, and the default flags will be set to
669@code{("-u")}. You can of course override this flag for a single diff
670by using a single @kbd{C-u} prefix argument.
671
11dac025
EZ
672@cindex Special prefix
673In addition to this, some commands can take @dfn{special prefix} arguments.
674These work as follows: When called with a @kbd{C-u} prefix, the user is
e9f75053
SM
675prompted for a new value of the special prefix and the special prefix is
676activated for the next command. When called without the @kbd{C-u}
677prefix, the special prefix is re-activated (with the same value as last
678time) for the next command. Calling the prefix command again when it's
679already activated deactivates it. Calling it with the @kbd{C-u C-u}
680prefix activates it for all subsequent commands until you deactivate it
681explicitly. The special prefixes are:
682
683@table @kbd
e9f75053
SM
684@item T
685Toggles whether or not marks will be active in the next command.@refill
686
687@item b
688Provide the next command with a branch (can be any version
689specifier) to work on.@refill
690
691@item B
11dac025 692Secondary branch argument. Only meaningful if @kbd{b} is also used.
e9f75053
SM
693It can be used to provide a second branch argument to
694@code{cvs-mode-diff} or to @code{cvs-mode-update}.
695
696@item M-f
697Forces the next command to apply to every selected file rather than only
698to the ones PCL-CVS thinks are relevant.
e9f75053
SM
699@end table
700
701@node Updating the buffer, Movement commands, Setting flags, Commands
702@section Updating the @samp{*cvs*} buffer
703@findex cvs-update
704@findex cvs-examine
705@findex cvs-status
706@findex cvs-mode-update
707@findex cvs-mode-examine
708@findex cvs-mode-status
709
710The following commands can be used from within the @samp{*cvs*} buffer
711to update the display:
712
713@table @kbd
e9f75053 714@item M-u
11dac025 715Runs the command @samp{cvs-update}.@refill
e9f75053
SM
716
717@item M-e
11dac025 718Runs the command @samp{cvs-examine}.@refill
e9f75053
SM
719
720@item M-s
11dac025 721Runs the command @samp{cvs-status}.@refill
e9f75053
SM
722@end table
723
11dac025 724In addition to the above commands which operate on the whole module,
e9f75053 725you can run the equivalent CVS command on just a subset of the
11dac025 726files/directories with these keys:
e9f75053
SM
727
728@table @kbd
e9f75053
SM
729@item O
730Runs @code{cvs-mode-update} on the selected files. When run on the
11dac025 731top-level directory, this is equivalent to @kbd{M-u}.@refill
e9f75053
SM
732
733@item e
734Runs @code{cvs-mode-examine} on the selected files. When run on the
11dac025 735top-level directory, this is equivalent to @kbd{M-e}.@refill
e9f75053 736
11dac025 737@findex cvs-status-mode
e9f75053
SM
738@item s
739Runs @code{cvs-mode-status} on the selected files. When run on the
11dac025 740top-level directory, this is equivalent to @kbd{M-s}, except that
e9f75053
SM
741CVS output will be shown in a @samp{*cvs-info*} buffer that will be
742put in @samp{cvs-status-mode}.@refill
e9f75053
SM
743@end table
744
745
746@node Movement commands, Marking files, Updating the buffer, Commands
747@section Movement Commands
748@cindex Movement Commands
749@findex cvs-mode-next-line
750@findex cvs-mode-previous-line
11dac025
EZ
751@kindex SPC@r{--Move down one file}
752@kindex n@r{--Move down one file}
753@kindex p@r{--Move up one file}
e9f75053
SM
754
755You can use most normal Emacs commands to move forward and backward in
756the buffer. Some keys are rebound to functions that take advantage of
757the fact that the buffer is a PCL-CVS buffer:
758
759
760@table @kbd
11dac025 761@item @key{SPC}
e9f75053
SM
762@itemx n
763These keys move the cursor one file forward, towards the end of the
764buffer (@code{cvs-mode-next-line}).@refill
765
766@itemx p
11dac025 767This key moves one file backward, towards the beginning of the buffer
e9f75053
SM
768(@code{cvs-mode-previous-line}).
769@end table
770
771
772@node Marking files, Committing changes, Movement commands, Commands
773@section Marking files
774@cindex Selecting files (commands to mark files)
775@cindex Marking files
11dac025
EZ
776@kindex m@r{--marking a file}
777@kindex M@r{--marking all files}
778@kindex u@r{--unmark a file}
779@kindex ESC DEL@r{--unmark all files}
780@kindex DEL@r{--unmark previous file}
781@kindex %@r{--mark files matching regexp}
89cda0c5 782@kindex S@r{--mark files in a particular state}
11dac025 783@kindex T@r{--toggle marks}
e9f75053
SM
784@findex cvs-mode-mark
785@findex cvs-mode-unmark
786@findex cvs-mode-mark-all-files
787@findex cvs-mode-unmark-all-files
788@findex cvs-mode-unmark-up
789@findex cvs-mode-mark-matching-files
89cda0c5 790@findex cvs-mode-mark-on-state
e9f75053
SM
791@findex cvs-mode-toggle-marks
792
793PCL-CVS works on a set of @dfn{selected files} (@pxref{Selected files}).
794You can mark and unmark files with these commands:
795
796@table @kbd
797@item m
798This marks the file that the cursor is positioned on. If the cursor is
11dac025 799positioned on a directory all files in that directory are marked.
e9f75053
SM
800(@code{cvs-mode-mark}).@refill
801
802@item u
803Unmark the file that the cursor is positioned on. If the cursor is on a
11dac025 804directory, all files in that directory are unmarked.
e9f75053
SM
805(@code{cvs-mode-unmark}).@refill
806
807@item M
808Mark @emph{all} files in the buffer (@code{cvs-mode-mark-all-files}).
809
810@item M-@key{DEL}
811Unmark @emph{all} files (@code{cvs-mode-unmark-all-files}).
812
813@item @key{DEL}
814Unmark the file on the previous line, and move point to that line
815(@code{cvs-mode-unmark-up}).
816
89cda0c5 817@item %
e9f75053
SM
818Mark all files matching a regular expression
819(@code{cvs-mode-mark-matching-files}).
820
89cda0c5
SM
821@item S
822Mark all files in a particular state, such as ``Modified'' or
823``Removed''. (@code{cvs-mode-mark-on-state}).
824
825@item T
e9f75053
SM
826Toggle use of marks for the next command (@code{cvs-mode-toggle-marks}).
827@end table
828
829
830@node Committing changes, Editing files, Marking files, Commands
831@section Committing changes
832@cindex Committing changes
e9f75053
SM
833@findex cvs-mode-commit
834@findex cvs-mode-commit-setup
11dac025
EZ
835@kindex c@r{--commit files}
836@kindex C@r{--commit files with @file{ChangeLog} message}
837@vindex cvs-auto-revert@r{ (variable)}
e9f75053
SM
838@cindex Commit buffer
839@cindex Edit buffer
840@cindex Erasing commit message
841@cindex Reverting buffers after commit
842
843Committing changes basically works as follows:
844
845@enumerate
846@item
847After having selected the files you want to commit, you type either
848@kbd{c} or @kbd{C} which brings up a special buffer
849@samp{*cvs-commit*}.@refill
850
851@item
852You type in the log message describing the changes you're about to
115209ba 853commit (@pxref{Log Edit Mode}).
e9f75053
SM
854
855@item
856When you're happy with it, you type @kbd{C-c C-c} to do the actual
857commit.@refill
e9f75053
SM
858@end enumerate
859
860There's no hidden state, so you can abort the process or pick it up
861again at any time.
862
11dac025 863@vindex log-edit-confirm@r{ (variable)}
e9f75053 864The set of files actually committed is really decided only during the
11dac025 865very last step, which is a mixed blessing. It allows you to go back and
e9f75053
SM
866change your mind about which files to commit, but it also means that you
867might inadvertently change the set of selected files. To reduce the
868risk of error, @kbd{C-c C-c} will ask for confirmation if the set of
869selected files has changed between the first step and the last. You can
870change this last detail with @code{log-edit-confirm}.
871
872As for the difference between @kbd{c} (i.e. @code{cvs-mode-commit}) and
873@kbd{C} (i.e. @code{cvs-mode-commit-setup}) is that the first gets you
874straight to @samp{*cvs-commit*} without erasing it or changing anything
11dac025
EZ
875to its content, while the second first erases @samp{*cvs-commit*}
876and tries to initialize it with a sane default (it does that by either
e9f75053 877using a template provided by the CVS administrator or by extracting a
11dac025 878relevant log message from a @file{ChangeLog} file).
e9f75053 879
11dac025 880If you are editing the files in your Emacs, an automatic
e9f75053 881@samp{revert-buffer} will be performed. (If the file contains
11dac025 882@samp{$@asis{Id}$} keywords, @samp{cvs commit} will write a new file with
e9f75053
SM
883the new values substituted. The auto-revert makes sure that you get
884them into your buffer). The revert will not occur if you have modified
885your buffer, or if @samp{cvs-auto-revert} is set to
886@samp{nil}.
887
888
889@node Editing files, Getting info about files, Committing changes, Commands
890@section Editing files
891@cindex Editing files
892@cindex Finding files
893@cindex Loading files
894@cindex Dired
895@cindex Invoking dired
896@findex cvs-mode-find-file
897@findex cvs-mode-find-file-other-window
898@findex cvs-mode-add-change-log-entry-other-window
11dac025
EZ
899@kindex f@r{--find file or directory}
900@kindex o@r{--find file in other window}
901@kindex A@r{--add @file{ChangeLog} entry}
e9f75053
SM
902
903There are currently three commands that can be used to find a file (that
904is, load it into a buffer and start editing it there). These commands
905work on the line that the cursor is situated at. They always ignore any marked
906files.
907
908@table @kbd
909@item f
11dac025
EZ
910Find the file that the cursor points to (@code{cvs-mode-find-file}). If
911the cursor points to a directory, run @code{dired} on that directory;
912@inforef{Dired, , emacs}.
e9f75053
SM
913
914@item o
915Like @kbd{f}, but use another window
916(@code{cvs-mode-find-file-other-window}).@refill
917
918@item A
919Invoke @samp{add-change-log-entry-other-window} to edit a
11dac025
EZ
920@file{ChangeLog} file. The @file{ChangeLog} file will be found in the
921directory of the file the cursor points to, or in a parent of that
922directory. (@code{cvs-mode-add-change-log-entry-other-window}).@refill
e9f75053
SM
923@end table
924
925
926@node Getting info about files, Adding and removing files, Editing files, Commands
927@section Getting info about files
928@cindex Status (cvs command)
929@cindex Log (RCS/cvs command)
930@cindex Getting status
11dac025
EZ
931@kindex l@r{--run @samp{cvs log}}
932@kindex s@r{--run @samp{cvs status}}
e9f75053
SM
933@findex cvs-mode-log
934@findex cvs-mode-status
935
936@table @kbd
937@item l
938Call the command @code{cvs-mode-log} which runs @samp{cvs log} on all
11dac025 939selected files, and show the result in a temporary buffer
115209ba 940@samp{*cvs-info*} (@pxref{Log View Mode}).
e9f75053
SM
941
942@item s
943Call the command @code{cvs-mode-status} which runs @samp{cvs status} on
11dac025 944all selected files, and show the result in a temporary buffer
e7610308
DL
945@samp{*cvs-info*}.
946@c Fixme: reinstate when node is written:
947@c (@pxref{CVS Status Mode}).
e9f75053
SM
948@end table
949
950
951@node Adding and removing files, Undoing changes, Getting info about files, Commands
952@section Adding and removing files
953@cindex Adding files
954@cindex Removing files
955@cindex Resurrecting files
956@cindex Deleting files
957@cindex Putting files under CVS control
11dac025
EZ
958@kindex a@r{--add a file}
959@kindex r@r{--remove a file}
e9f75053
SM
960@findex cvs-mode-add
961@findex cvs-mode-remove-file
962
11dac025
EZ
963The following commands are available to make it easy to add fuiles to
964and remove them from the CVS repository.
e9f75053
SM
965
966@table @kbd
967@item a
968Add all selected files. This command can be used on @samp{Unknown}
969files (@pxref{Buffer contents}). The status of the file will change to
11dac025
EZ
970@samp{Added}, and you will have to use @kbd{c} (@samp{cvs-mode-commit}
971@pxref{Committing changes}), to really add the file to the
e9f75053
SM
972repository.@refill
973
974This command can also be used on @samp{Removed} files (before you commit
975them) to resurrect them.
976
977The command that is run is @code{cvs-mode-add}.
978
979@item r
980This command removes the selected files (after prompting for
11dac025 981confirmation). The files are deleted from your directory and
e9f75053 982(unless the status was @samp{Unknown}; @pxref{Buffer contents}) they will
11dac025
EZ
983also be @samp{cvs remove}d. If the files' status was @samp{Unknown}
984they will disappear from the buffer. Otherwise their status will change to
e9f75053
SM
985@samp{Removed}, and you must use @kbd{c} (@samp{cvs-mode-commit},
986@pxref{Committing changes}) to commit the removal.@refill
987
988The command that is run is @code{cvs-mode-remove-file}.
989@end table
990
991
992@node Undoing changes, Removing handled entries, Adding and removing files, Commands
993@section Undoing changes
994@cindex Undo changes
995@cindex Flush changes
11dac025 996@kindex U@r{--undo changes}
e9f75053
SM
997@findex cvs-mode-undo-local-changes
998
999@table @kbd
1000@item U
1001If you have modified a file, and for some reason decide that you don't
1002want to keep the changes, you can undo them with this command. It works
1003by removing your working copy of the file and then getting the latest
1004version from the repository (@code{cvs-mode-undo-local-changes}.
1005@end table
1006
1007
1008@node Removing handled entries, Ignoring files, Undoing changes, Commands
1009@section Removing handled entries
1010@cindex Expunging uninteresting entries
1011@cindex Uninteresting entries, getting rid of them
1012@cindex Getting rid of uninteresting lines
1013@cindex Removing uninteresting (processed) lines
1014@cindex Handled lines, removing them
11dac025
EZ
1015@kindex x@r{--remove processed entries}
1016@kindex C-k@r{--remove selected entries}
e9f75053
SM
1017@findex cvs-mode-remove-handled
1018@findex cvs-mode-acknowledge
1019@findex cvs-mode-ignore
1020
1021@table @kbd
1022@item x
1023This command allows you to remove all entries that you have processed.
1024More specifically, the lines for @samp{Up-to-date} files (@pxref{Buffer
11dac025
EZ
1025contents}) are removed from the buffer. If a directory becomes empty
1026the heading for that directory is also removed. This makes it easier to
1027get an overview of what needs to be done.
e9f75053 1028
11dac025
EZ
1029@vindex cvs-mode-remove-handled@r{ (variable)}
1030@kbd{x} invokes @code{cvs-mode-remove-handled}. If
1031@samp{cvs-auto-remove-handled} is set to non-@code{nil}, this will
e9f75053
SM
1032automatically be performed after every commit.@refill
1033
1034@item C-k
1035This command can be used for lines that @samp{cvs-mode-remove-handled} would
1036not delete, but that you want to delete (@code{cvs-mode-acknowledge}).
1037@end table
1038
1039
1040@node Ignoring files, Viewing differences, Removing handled entries, Commands
1041@section Ignoring files
11dac025
EZ
1042@cindex Ignoring files
1043@kindex i@r{--ignoring files}
e9f75053
SM
1044@findex cvs-mode-ignore
1045
1046@table @kbd
1047@item i
1048Arrange so that CVS will ignore the selected files. The file names are
1049added to the @file{.cvsignore} file in the corresponding directory. If
11dac025 1050the @file{.cvsignore} file doesn't exist, it will be created.
e9f75053
SM
1051
1052The @file{.cvsignore} file should normally be added to the repository,
11dac025 1053but you could ignore it as well, if you like it better that way.
e9f75053
SM
1054
1055This runs @code{cvs-mode-ignore}.
1056@end table
1057
1058@node Viewing differences, Invoking Ediff, Ignoring files, Commands
1059@section Viewing differences
1060@cindex Diff
11dac025 1061@cindex Invoking @code{diff}
e9f75053
SM
1062@cindex Conflicts, how to resolve them
1063@cindex Viewing differences
11dac025
EZ
1064@kindex d=@r{--run @samp{cvs diff}}
1065@kindex =@r{--run @samp{cvs diff}}
1066@kindex db@r{--diff against base version}
1067@kindex dh@r{--diff against head of repository}
1068@kindex dv@r{--diff against vendor branch}
e9f75053
SM
1069@findex cvs-mode-diff
1070@findex cvs-mode-diff-backup
1071@findex cvs-mode-diff-head
1072@findex cvs-mode-diff-vendor
11dac025 1073@vindex cvs-invert-ignore-marks@r{ (variable)}
e9f75053
SM
1074
1075@table @kbd
1076@item =
1077@itemx d =
1078Display a @samp{cvs diff} between the selected files and the version
1079that they are based on. (@code{cvs-mode-diff}).@refill
1080
1081@item d b
1082If CVS finds a conflict while merging two versions of a file (during a
1083@samp{cvs update}, @pxref{Updating the buffer}) it will save the
11dac025
EZ
1084original file in a file called @file{.#@var{file}.@var{version}} where
1085@var{file} is the name of the file, and @var{version} is the revision
1086number that @var{file} was based on.@refill
e9f75053 1087
11dac025
EZ
1088With the @kbd{d b} command you can run a @samp{diff} on the files
1089@file{.#@var{file}.@var{version}} and @file{@var{file}}.@refill
e9f75053
SM
1090
1091@item d h
1092Display a @samp{cvs diff} between the selected files and the head
1093revision in the repository (the most recent version on the current
11dac025 1094branch) (@code{cvs-mode-diff-head}).@refill
e9f75053
SM
1095
1096@item d v
1097Display a @samp{cvs diff} between the selected files and the head
1098revision of the vendor branch in the repository.
1099(@code{cvs-mode-diff-vendor}).@refill
e9f75053
SM
1100@end table
1101
1102By default, @samp{diff} commands ignore the marks. This can be changed
1103with @code{cvs-invert-ignore-marks}.
1104
1105@node Invoking Ediff, Updating files, Viewing differences, Commands
1106@section Running ediff
1107@cindex Ediff
1108@cindex Invoking ediff
1109@cindex Viewing differences
11dac025 1110@cindex Conflicts, how to resolve them
e9f75053 1111@cindex Resolving conflicts
11dac025 1112@kindex e@r{--invoke @samp{ediff}}
e9f75053
SM
1113@findex cvs-mode-idiff
1114@findex cvs-mode-imerge
1115
1116@table @kbd
11dac025 1117@vindex cvs-idiff-imerge-handlers@r{ (variable)}
e9f75053 1118@item d e
11dac025 1119This uses @code{ediff} (or @code{emerge}, depending on
e9f75053
SM
1120@samp{cvs-idiff-imerge-handlers}) to allow you to view diffs.
1121If a prefix argument is given, PCL-CVS will prompt for a revision against
1122which the diff should be made, else the default will be to use the BASE
1123revision.
1124
11dac025 1125@cindex Merging with @code{ediff} and @code{emerge}
e9f75053 1126@item d E
11dac025
EZ
1127This command use @code{ediff} (or @code{emerge}, see above) to allow you
1128to do an interactive 3-way merge.
e9f75053
SM
1129
1130@strong{Note:} When the file status is @samp{Conflict},
1131CVS has already performed a merge. The resulting file is not used in
1132any way if you use this command. If you use the @kbd{q} command inside
1133@samp{ediff} (to successfully terminate a merge) the file that CVS
1134created will be overwritten.@refill
e9f75053
SM
1135@end table
1136
1137@node Updating files, Tagging files, Invoking Ediff, Commands
1138@section Updating files
1139@findex cvs-mode-update
1140@cindex Updating files
11dac025 1141@kindex O@r{--update files}
e9f75053
SM
1142
1143@table @kbd
1144@item O
1145Update all selected files with status @samp{Need-update} by running
1146@samp{cvs update} on them. (@code{cvs-mode-update}).
1147@end table
1148
1149
1150@node Tagging files, Miscellaneous commands, Updating files, Commands
1151@section Tagging files
1152@findex cvs-mode-tag
1153@findex cvs-mode-untag
1154@findex cvs-rtag
1155@cindex Tagging files
11dac025
EZ
1156@kindex M-t@r{--repository tag files}
1157@kindex t@r{--tag files}
1158@vindex cvs-invert-ignore-marks@r{ (variable)}
1159@vindex cvs-force-dir-tag@r{ (variable)}
e9f75053
SM
1160
1161@table @kbd
1162@item t
1163Tag all selected files by running @samp{cvs tag} on
11dac025 1164them (@code{cvs-mode-tag}). It's usually preferable to tag a directory
e9f75053
SM
1165at a time. Rather than selecting all files (which too often doesn't
1166select all files but only the few that are displayed), clear the
1167selection with @kbd{M-DEL} (@code{cvs-mode-unmark-all-files}), position
1168the cursor on the directory you want to tag and hit @kbd{t}.
e9f75053
SM
1169@end table
1170
1171By default, @samp{tag} commands ignore the marks. This can be changed
11dac025 1172with @code{cvs-invert-ignore-marks}. Also, by default @samp{tag} can
e9f75053
SM
1173only be applied to directories, see @code{cvs-force-dir-tag} if you want
1174to change this behavior.
1175
1176
1177@node Miscellaneous commands, , Tagging files, Commands
1178@section Miscellaneous commands
1179@findex cvs-mode-byte-compile-files
1180@cindex Recompiling elisp files
1181@cindex Byte compilation
1182@findex cvs-mode-delete-lock
1183@cindex Getting rid of lock files
1184@cindex Lock files
11dac025 1185@kindex q@r{--quit PCL-CVS}
e9f75053
SM
1186@findex cvs-mode-quit
1187@cindex Quitting
11dac025
EZ
1188@kindex h@r{--help}
1189@kindex ?@r{--help}
e9f75053
SM
1190@findex cvs-help
1191@cindex Help
1192
1193@table @kbd
1194@item M-x cvs-mode-byte-compile-files
11dac025 1195Byte compile all selected files that end in @file{.el}.
e9f75053
SM
1196
1197@item M-x cvs-mode-delete-lock
1198This command deletes the lock files that
11dac025
EZ
1199the @samp{*cvs*} buffer informs you about. You should normally never have to
1200use this command, since CVS tries very carefully to always remove the
e9f75053
SM
1201lock files itself.
1202
11dac025 1203You can only use this command when a message in the @samp{*cvs*} buffer tells
e9f75053 1204you so. You should wait a while before using this command in case
11dac025 1205someone else is running a @code{cvs} command.
e9f75053
SM
1206
1207Also note that this only works if the repository is local.
1208
1209@item ?
1210@itemx h
1211Show a summary of common command key bindings in the echo
11dac025 1212area (@code{cvs-help}).
e9f75053
SM
1213
1214@item q
11dac025 1215Quit PCL-CVS, killing the @samp{*cvs*} buffer (@code{cvs-mode-quit}).
e9f75053
SM
1216@end table
1217
115209ba
DL
1218@node Log Edit Mode, Log View Mode, Commands, Top
1219@chapter Editing a Log Message
1220
1221@cindex Log Edit mode
1222@cindex mode, Log Edit
1223Buffers for entering/editing log messages for changes which are about
1224to be committed are put into Log Edit mode.
1225
1226Sometimes the log buffer contains default text when you enter it,
1227typically the last log message entered. If it does, mark and point
1228are set around the entire contents of the buffer so that it is easy to
1229kill the contents of the buffer with @kbd{C-w}.
1230
1231@findex log-edit-insert-changelog
1232If you work by writing entries in the @file{ChangeLog}
1233(@pxref{(emacs)Change Log}) and then commit the change under revision
1234control, you can generate the Log Edit text from the ChangeLog using
1235@kbd{C-a C-a} (@kbd{log-edit-insert-changelog}). This looks for
1236entries for the file(s) concerned in the top entry in the ChangeLog
1237and uses those paragraphs as the log text. This text is only inserted
1238if the top entry was made under your user name on the current date.
1239@xref{(emacs)Change Logs and VC}, for the opposite way of
1240working---generating ChangeLog entries from the revision control log.
1241
1242In the Log Edit buffer, @kbd{C-c C-f} (@kbd{M-x log-edit-show-files})
1243shows the list of files to be committed in case you need to check
1244that.
1245
1246When you have finished editing the log message, type @kbd{C-c C-c} to
1247exit the buffer and commit the change.
1248
1249@c Fixme: customization variables
1250
1251@node Log View Mode, Customization, Log Edit Mode, Top
1252@chapter Browsing a Log of Changes
1253
1254@cindex Log View mode
1255@cindex mode, Log View
1256@cindex output, logs
1257
1258@findex cvs-mode-log
1259@findex vc-print-log
1260Log View mode provides a few useful commands for navigating revision
1261control log output. It is used for the output buffers of both
1262@code{cvs-mode-log} and @code{vc-print-log}.
e9f75053 1263
115209ba
DL
1264In this mode, @kbd{n} goes to the next message and @kbd{p} goes to the
1265previous message and @kbd{N} and @kbd{P} go to the next and previous
1266files, respectively, in multi-file output. With a numeric prefix
1267argument, these commands move that many messages of files.
e9f75053 1268
115209ba 1269@c @node CVS Status Mode
e7610308 1270@c @chapter Viewing CVS' Status output
e9f75053 1271
115209ba 1272@node Customization, Bugs, Log View Mode, Top
e9f75053 1273@chapter Customization
11dac025
EZ
1274@vindex log-edit-changelog-full-paragraphs@r{ (variable)}
1275@vindex cvs-auto-remove-handled@r{ (variable)}
1276@vindex cvs-auto-remove-directories@r{ (variable)}
1277@vindex cvs-update-prog-output-skip-regexp@r{ (variable)}
1278@vindex cvs-cvsroot@r{ (variable)}
1279@vindex cvs-auto-revert@r{ (variable)}
1280@vindex log-edit-require-final-newline@r{ (variable)}
1281@vindex cvs-sort-ignore-file@r{ (variable)}
e9f75053
SM
1282@cindex Customization
1283@cindex Variables, list of all
11dac025 1284@cindex Erasing input buffer
e9f75053
SM
1285@cindex Context diff, how to get
1286@cindex Unidiff, how to get
1287@cindex Automatically remove handled files
11dac025
EZ
1288@cindex @samp{-u} option in modules file
1289@cindex Modules file (@samp{-u} option)
1290@cindex Update program (@samp{-u} option in modules file)
e9f75053
SM
1291@cindex Reverting buffers after commit
1292@cindex Require final newline
1293@cindex Automatically inserting newline
1294@cindex Commit message, inserting newline
11dac025
EZ
1295@cindex Sorting @file{.cvsignore} file
1296@cindex @file{.cvsignore} file, sorting
1297@cindex Automatically sorting @file{.cvsignore}
1298@cindex @samp{CVSROOT}, overriding
e9f75053
SM
1299
1300If you have an idea about any customization that would be handy but
1301isn't present in this list, please tell me!
11dac025 1302For info on how to reach me, see @ref{Bugs}.@refill
e9f75053
SM
1303
1304@table @samp
1305@item cvs-auto-remove-handled
11dac025 1306If this variable is set to any non-@code{nil} value,
e9f75053
SM
1307@samp{cvs-mode-remove-handled} will be called every time you check in
1308files, after the check-in is ready. @xref{Removing handled
1309entries}.@refill
1310
1311@item cvs-auto-remove-directories
1312If this variable is set to any non-@code{nil} value, directories that do
1313not contain any files to be checked in will not be listed in the
1314@samp{*cvs*} buffer.@refill
1315
1316@item cvs-auto-revert
1317If this variable is set to any non-@samp{nil} value any buffers you have
1318that visit a file that is committed will be automatically reverted.
1319This variable defaults to @samp{t}. @xref{Committing changes}.@refill
1320
1321@item cvs-update-prog-output-skip-regexp
1322The @samp{-u} flag in the @file{modules} file can be used to run a command
11dac025 1323whenever a @samp{cvs update} is performed (see @code{cvs(5)}). This regexp
e9f75053 1324is used to search for the last line in that output. It is normally set
11dac025 1325to @samp{$}. That setting is only correct if the command outputs
e9f75053 1326nothing. Note that PCL-CVS will get very confused if the command
11dac025 1327outputs @emph{anything} to @code{stderr}.
e9f75053
SM
1328
1329@item cvs-cvsroot
1330This variable can be set to override @samp{CVSROOT}. It should be a
11dac025
EZ
1331string. If it is set, then every time a @code{cvs} command is run, it
1332will be called as @samp{cvs -d @var{cvs-cvsroot}@dots{}}. This can be
1333useful if your site has several repositories.
e9f75053
SM
1334
1335@item log-edit-require-final-newline
11dac025
EZ
1336@c wordy to avoid unhderfull hbox
1337When you enter a log message by typing into the
1338@samp{*cvs-commit-message*} buffer, PCL-CVS normally automatically
1339inserts a trailing newline, unless there already is one. This behavior
1340can be controlled via @samp{cvs-commit-buffer-require-final-newline}.
1341If it is @samp{t} (the default behavior), a newline will always be
1342appended. If it is @samp{nil}, newlines will never be appended. Any
1343other value causes PCL-CVS to ask the user whenever there is no trailing
1344newline in the commit message buffer.
1345
1346@findex cvs-mode-changelog-commit
e9f75053 1347@item log-edit-changelog-full-paragraphs
11dac025
EZ
1348If this variable is non-@code{nil}, include full @file{ChangeLog}
1349paragraphs in the CVS log created by @samp{cvs-mode-changelog-commit}.
1350This may be set in the local variables section of a @file{ChangeLog}
1351file, to indicate the policy for that @file{ChangeLog}.
e9f75053 1352
11dac025
EZ
1353@cindex @file{ChangeLog} paragraphs
1354A @dfn{@file{ChangeLog} paragraph} is a bunch of log text containing no
1355blank lines; a paragraph usually describes a set of changes with a
1356single purpose, but perhaps spanning several functions in several files.
1357Changes in different paragraphs are unrelated.
e9f75053
SM
1358
1359You could argue that the CVS log entry for a file should contain the
11dac025 1360full @file{ChangeLog} paragraph mentioning the change to the file, even though
e9f75053
SM
1361it may mention other files, because that gives you the full context you
1362need to understand the change. This is the behavior you get when this
11dac025 1363variable is set to @code{t}, the default.
e9f75053
SM
1364
1365On the other hand, you could argue that the CVS log entry for a change
1366should contain only the text for the changes which occurred in that
1367file, because the CVS log is per-file. This is the behavior you get
11dac025 1368when this variable is set to @code{nil}.
e9f75053 1369
11dac025 1370@findex cvs-mode-ignore@r{, and @file{.cvsignore} sorting}
e9f75053 1371@item cvs-sort-ignore-file
11dac025
EZ
1372If this variable is set to any non-@samp{nil} value, the
1373@file{.cvsignore} file will always be sorted whenever you use
e9f75053
SM
1374@samp{cvs-mode-ignore} to add a file to it. This option is on by
1375default.
e9f75053
SM
1376@end table
1377
1378
1379@menu
1380* Customizing Faces::
1381@end menu
1382
1383@node Customizing Faces, , Customization, Customization
1384@section Customizing Faces
1385@vindex cvs-header-face (face)
1386@vindex cvs-filename-face (face)
1387@vindex cvs-unknown-face (face)
1388@vindex cvs-handled-face (face)
1389@vindex cvs-need-action-face (face)
1390@vindex cvs-marked-face (face)
1391
11dac025 1392PCL-CVS adds a few extra features, including menus, mouse bindings, and
c40523ad 1393fontification the @samp{*cvs*} buffer. The faces defined for
e9f75053
SM
1394fontification are listed below:
1395
1396@table @samp
e9f75053 1397@item cvs-header-face
11dac025 1398used to highlight directory changes.
e9f75053
SM
1399
1400@item cvs-filename-face
11dac025 1401used to highlight file names.
e9f75053
SM
1402
1403@item cvs-unknown-face
11dac025 1404used to highlight the status of files which are @samp{Unknown}.
e9f75053
SM
1405
1406@item cvs-handled-face
11dac025 1407used to highlight the status of files which are handled and
e9f75053
SM
1408need no further action.
1409
1410@item cvs-need-action-face
11dac025 1411used to highlight the status of files which still need action.
e9f75053
SM
1412
1413@item cvs-marked-face
11dac025 1414used to highlight the marked file indicator (@samp{*}).
e9f75053
SM
1415@end table
1416
1417
1418@node Bugs, Function and Variable Index, Customization, Top
1419@chapter Bugs (known and unknown)
1420@cindex Reporting bugs and ideas
1421@cindex Bugs, how to report them
1422@cindex Author, how to reach
1423@cindex Email to the author
1424@cindex Known bugs
1425@cindex Bugs, known
1426@cindex FAQ
1427@cindex Problems, list of common
1428
1429If you find a bug or misfeature, don't hesitate to tell us! Send email
11dac025 1430to @email{bug-gnu-emacs@@gnu.org} which is gatewayed to the newsgroup
e9f75053
SM
1431@samp{gnu.emacs.bugs}. Feature requests should also be sent there. We
1432prefer discussing one thing at a time. If you find several unrelated
1433bugs, please report them separately. If you are running PCL-CVS under
1434XEmacs, you should also send a copy of bug reports to
11dac025 1435@email{xemacs-beta@@xemacs.org}.
e9f75053 1436
11dac025
EZ
1437If you have problems using PCL-CVS or other questions, send them to
1438@email{help-gnu-emacs@@gnu.org}, which is gatewayed to the
1439@samp{gnu.emacs.help} newsgroup. This is a good place to get help, as
1440is @email{cvs-info@@gnu.org}, gatewayed to @samp{gnu.cvs.help}.
e9f75053
SM
1441
1442If you have ideas for improvements, or if you have written some
1443extensions to this package, we would like to hear from you. We hope that
1444you find this package useful!
1445
89cda0c5 1446Below is a partial list of currently known problems with PCL-CVS.
e9f75053
SM
1447
1448@table @asis
1449@item Unexpected output from CVS
1450Unexpected output from CVS may confuse PCL-CVS. It will create
11dac025 1451warning messages in the @samp{*cvs*} buffer alerting you to any parse errors.
e9f75053 1452If you get these messages, please send a bug report to the email
11dac025 1453addresses listed above. Include the contents of the @samp{*cvs*} buffer, the
89cda0c5 1454output of the CVS process (which should be found in the @samp{ *cvs-tmp*}
e9f75053 1455buffer), and the versions of Emacs, PCL-CVS and CVS you are using.
e9f75053
SM
1456@end table
1457
1458@node Function and Variable Index, Concept Index, Bugs, Top
1459@unnumbered Function and Variable Index
1460
11dac025
EZ
1461This is an index of all the functions and variables documented in this
1462manual.
1463
e9f75053
SM
1464@printindex fn
1465
1466@node Concept Index, Key Index, Function and Variable Index, Top
1467@unnumbered Concept Index
1468
11dac025
EZ
1469This is an index of concepts discussed in this manual.
1470
e9f75053
SM
1471@printindex cp
1472
1473@node Key Index, , Concept Index, Top
1474@unnumbered Key Index
1475
11dac025
EZ
1476This index includes an entry for each PCL-CVS key sequence documented in
1477this manual.
1478
e9f75053
SM
1479@printindex ky
1480
1481@setchapternewpage odd
1482@summarycontents
1483@contents
1484@bye