Annotation of src/usr.bin/cvs/cvs.1, Revision 1.93
1.93 ! xsa 1: .\" $OpenBSD: cvs.1,v 1.92 2006/01/06 17:09:01 jmc Exp $
1.1 jfb 2: .\"
3: .\" Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
1.36 xsa 4: .\" Copyright (c) 2004, 2005 Xavier Santolaria <xsa@openbsd.org>
1.1 jfb 5: .\" All rights reserved.
6: .\"
7: .\" Redistribution and use in source and binary forms, with or without
8: .\" modification, are permitted provided that the following conditions
9: .\" are met:
10: .\"
11: .\" 1. Redistributions of source code must retain the above copyright
12: .\" notice, this list of conditions and the following disclaimer.
13: .\" 2. The name of the author may not be used to endorse or promote products
14: .\" derived from this software without specific prior written permission.
15: .\"
16: .\" THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
17: .\" INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
18: .\" AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
19: .\" THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
20: .\" EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
21: .\" PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
22: .\" OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
23: .\" WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
24: .\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
25: .\" ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26: .\"
27: .Dd May 16, 2004
28: .Dt CVS 1
29: .Os
30: .Sh NAME
31: .Nm cvs
1.68 joris 32: .Nd OpenCVS Concurrent Versioning System
1.1 jfb 33: .Sh SYNOPSIS
34: .Nm
1.84 jmc 35: .Bk -words
1.83 xsa 36: .Op Fl flnQqrtvw
1.1 jfb 37: .Op Fl d Ar root
38: .Op Fl e Ar editor
1.20 jmc 39: .Xo
40: .Oo Fl s
41: .Ar var Ns = Ns Ar val Oc
42: .Xc
1.77 xsa 43: .Op Fl T Ar tmpdir
1.15 jmc 44: .Op Fl z Ar level
1.1 jfb 45: .Ar command Op Ar ...
1.84 jmc 46: .Ek
1.1 jfb 47: .Sh DESCRIPTION
48: The
49: .Nm
50: program acts as both client and server for the use of and administration of
51: a CVS source repository.
52: CVS is used to maintain version information on files that are kept in a
53: repository.
54: Although it is more commonly used to track changes in source code, there
55: are no real limitations to the type of files that you can store in a
56: repository.
1.35 jmc 57: For a general introduction to CVS, see
58: .Xr cvsintro 7 .
1.1 jfb 59: .Pp
1.7 jfb 60: .Nm
1.35 jmc 61: reads its startup configuration file,
62: .Pa .cvsrc ,
1.7 jfb 63: from the home directory of the user who invoked it.
64: This file is used to specify implicit options passed to
65: .Nm
66: or one of its commands whenever it is invoked.
1.35 jmc 67: The defaults in the configuration file can be overridden with the
68: .Fl f
69: option (see below).
1.16 jmc 70: See
71: .Xr cvsrc 5
72: for further information.
1.7 jfb 73: .Pp
1.1 jfb 74: The following options are supported:
1.61 deraadt 75: .Bl -tag -width Ds
1.1 jfb 76: .It Fl d Ar root
77: Use
78: .Ar root
79: as the path to the root directory of the CVS repository.
80: The value must specify an absolute path.
81: .It Fl e Ar editor
82: Use the program
83: .Ar editor
84: whenever editing log information.
1.8 jmc 85: This option overrides the environment variables CVSEDITOR, VISUAL, and EDITOR.
1.1 jfb 86: .It Fl f
1.7 jfb 87: Do not read the user's configuration file on startup.
1.1 jfb 88: .It Fl l
89: Suppress logging of history information.
1.67 xsa 90: .It Fl n
91: Dry-run mode.
92: Show which files will be used by the command issued
93: without really running it.
1.1 jfb 94: .It Fl Q
95: Be extra quiet.
96: Only error messages will be displayed.
97: .It Fl q
98: Be quiet about reporting.
1.70 xsa 99: .It Fl r
100: Extract files in read-only mode.
1.20 jmc 101: .It Fl s Ar var Ns = Ns Ar val
102: Set the value of the internal variable
103: .Ar var
104: to the string
105: .Ar val .
1.77 xsa 106: .It Fl T Ar tmpdir
107: Set the value of the directory where temporary files are to be created.
108: The default is set to
109: .Pa /tmp .
1.15 jmc 110: .It Fl t
111: Trace program execution.
1.1 jfb 112: .It Fl v
113: Display version information and exit.
1.83 xsa 114: .It Fl w
115: Extract new files in read-write mode.
116: Overrides the setting of the
117: .Ev CVSREAD
118: environment variable.
119: This is the default unless
120: .Ev CVSREAD
121: is set or the
122: .Fl r
123: option is specified.
1.15 jmc 124: .It Fl z Ar level
125: Specify the compression level to
126: .Xr gzip 1
127: when transferring files.
128: The compression level ranges from 1 to 9,
129: with 1 being the fastest,
130: and 9 providing the best level of compression.
131: The default is 6.
1.45 xsa 132: .El
133: .Sh KEYWORD SUBSTITUTION
134: As long as you edit source files inside a working directory you
135: can always find out the state of your files via the
136: .Ic status
137: or
138: .Ic log
139: commands, but as soon as files get exported from
140: your local working copy, it becomes harder to identify which
141: revisions they are.
142: .Pp
143: .Nm
144: can use a mechanism known as
145: .Sq keyword substitution
146: to help identify the files.
147: Embedded strings of the form $keyword$ and $keyword:...$ in a file
148: are replaced with strings of the form $keyword: value$ whenever you
149: obtain a new revision of the file.
150: The possible keywords are as follows:
1.61 deraadt 151: .Bl -tag -width Ds
1.48 xsa 152: .It $\&Author$
1.45 xsa 153: The name of the user who checked in the revision.
1.48 xsa 154: .It $\&Date$
1.45 xsa 155: The date and hour (UTC) the revision was checked in.
1.48 xsa 156: .It $\&Header$
1.45 xsa 157: Standard header containing the full pathname of the RCS
158: file, the revision number, the date (UTC), the author and the state.
1.48 xsa 159: .It $\&Id$
160: The same content as $\&Header$ but without the path
1.45 xsa 161: of the RCS file.
1.48 xsa 162: .It $\&Log$
1.45 xsa 163: The log message supplied during commit, preceded by a header
164: containing the RCS filename, the revision number, the
165: author, and the date (UTC).
1.48 xsa 166: .It $\&Name$
1.45 xsa 167: The tag name used to check out the file.
1.48 xsa 168: .It $\&RCSfile$
1.45 xsa 169: The name of the RCS file, but without a path.
1.48 xsa 170: .It $\&Revision$
1.45 xsa 171: The revision number assigned to the revision.
1.48 xsa 172: .It $\&Source$
1.45 xsa 173: The full pathname of the RCS file.
1.48 xsa 174: .It $\&State$
1.45 xsa 175: The state assigned to the revision.
176: .El
177: .Pp
178: Keyword substitution has its disadvantages: sometimes the
1.48 xsa 179: literal text string $\&Author$ is wanted inside a file without
1.45 xsa 180: .Nm
181: interpreting it as a keyword and expanding it into something like
1.48 xsa 182: $\&Author$.
1.45 xsa 183: The
184: .Fl k Ar o
1.48 xsa 185: option can be used to turn off keyword substitution entirely though.
1.45 xsa 186: There is unfortunately no way to selectively turn off keyword substitution.
187: .Pp
188: Each file and working directory copy of a file have a stored
189: default substitution mode.
190: Substitution modes on files are set by the
191: .Fl k Ar mode
192: option to the
193: .Ic add
194: and
195: .Ic admin
196: commands or by the
197: .Fl k Ar mode
198: or
199: .Fl A
200: options to the
201: .Ic checkout
202: or
203: .Ic update
204: commands.
205: .Pp
206: The possible substitution modes are as follows:
207: .Bl -tag -width Ds -offset 3n
208: .It Fl k Ar b
209: Like
210: .Fl k Ar o ,
211: but also avoids the conversion of line endings.
212: This option is used to handle binary files.
213: .It Fl k Ar k
214: Does not substitute the keywords.
215: Useful with the
216: .Ic diff
217: command to avoid displaying the differences between keyword substitutions.
218: .It Fl k Ar kv
219: The default behaviour.
1.48 xsa 220: Keywords are normally substituted i.e. $\&Revision$ becomes
221: $\&Revision: 1.1 $.
1.45 xsa 222: .It Fl k Ar kvl
223: Like
224: .Fl k Ar kv ,
225: except that the locker's name is displayed along with the version
226: if the given revision is currently locked.
227: This option is normally not useful as
228: .Nm
229: does not use file locking by default.
230: .It Fl k Ar o
231: No substitutions are done.
232: This option is often used with the
233: .Ic import
234: command to guarantee that files that already contain external keywords
235: do not get modified.
236: .It Fl k Ar v
1.54 david 237: Substitute the value of keywords instead of keywords themselves
1.48 xsa 238: e.g. instead of $\&Revision$, only insert 1.1 and not $\&Revision: 1.1 $.
1.45 xsa 239: This option must be used with care, as it can only be used once.
240: It is often used with the
241: .Ic export
242: command to freeze the values before releasing software.
1.1 jfb 243: .El
244: .Sh COMMANDS
1.91 jmc 245: .Nm
246: supports the following commands:
247: add,
248: admin,
249: annotate,
250: checkout,
251: commit,
252: diff,
253: edit,
254: editors,
255: export,
256: history,
257: import,
258: init,
259: kserver,
260: log,
261: login,
262: logout,
263: rdiff,
264: release,
265: remove,
266: rlog,
267: rtag,
268: server,
269: status,
270: tag,
271: unedit,
272: update,
273: version,
274: watch,
275: watchers.
276: The commands are fully explained in this section.
277: .Ss add
1.42 xsa 278: Before a file is known to
279: .Nm ,
280: it must be added to the repository using this command.
1.1 jfb 281: Adding a file does not actually publish the contents of the
1.42 xsa 282: file: the
1.11 jmc 283: .Ic commit
1.42 xsa 284: command must also be used to publish it into the repository,
285: and thus let others access the file.
286: .Pp
287: Note: since directories have no versioning system, it is sufficient
288: to add them with the
289: .Ic add
290: command alone; the
291: .Ic commit
292: command is not necessary.
1.91 jmc 293: .Bd -literal -offset indent
294: Usage: cvs add [-k mode] [-m msg] file ...
295: .Ed
1.1 jfb 296: .Pp
1.35 jmc 297: The
298: .Ic add
299: command takes the following options:
300: .Bl -tag -width Ds -offset 3n
1.42 xsa 301: .It Fl k Ar mode
302: Specify the keyword substitution mode.
1.35 jmc 303: .It Fl m Ar msg
304: Attach log message
305: .Ar msg .
306: By default, no log message is required.
307: .El
1.13 jmc 308: .Pp
309: Aliases:
310: .Ic ad ,
311: .Ic new .
1.91 jmc 312: .Ss admin
1.59 xsa 313: The
314: .Ic admin
315: command is used to directly modify the RCS files.
1.91 jmc 316: .Bd -literal -offset indent
317: Usage: cvs admin [-Iq] [-b branch] [-k mode] [-m rev:msg]
318: [-N tag[:rev]] [-n tag[:rev]] [-o rev]
319: [-s state[:rev]] [-t file | str]
320: .Ed
1.59 xsa 321: .Pp
322: The
323: .Ic admin
324: command takes the following options:
325: .Bl -tag -width Ds -offset 3n
326: .It Fl b Ar branch
327: Set the default branch to
328: .Ar branch .
329: .It Fl I
330: Command is interactive.
1.69 moritz 331: .It Fl k Ar mode
1.59 xsa 332: Specify the keyword substitution mode.
333: .It Fl m Ar rev : Ns Ar msg
334: Change the log message of a revision.
335: .It Xo Fl N
336: .Ar tag Ns Op : Ns Ar rev
337: .Xc
338: Same as
339: .Fl n ,
340: but override tag if it already exists.
341: .It Xo Fl n
342: .Ar tag Ns Op : Ns Ar rev
343: .Xc
344: Associate the
345: .Ar tag
346: with the
347: .Ar rev
348: or the branch given as argument.
349: If the revision or the branch is not specified, the tag is deleted.
350: The
351: .Sq \&:
352: character means the association of the tag and the latest revision of
353: the default branch.
354: A branch number ending with the
355: .Sq \&.
356: character means the current latest revision in the branch.
357: This option is functionally the same as the
358: .Ic rtag
359: command, but it avoids the check of the tags done with the
360: .Pa CVSROOT/taginfo
361: file.
362: .It Fl o Ar rev
363: Delete one or more revisions.
364: The specifications of the values or revisions are as follows:
1.61 deraadt 365: .Bl -tag -width Ds
1.59 xsa 366: .It rev
367: Specific revision.
368: .It rev1:rev2
369: Delete all revisions of a branch between
370: .Ar rev1
371: and
372: .Ar rev2 .
373: .It rev1::rev2
374: Delete all revisions of a branch between
375: .Ar rev1
376: and
377: .Ar rev2
378: without deleting revisions
379: .Ar rev1
380: and
381: .Ar rev2 .
382: .It :rev
383: Delete all revisions of the branch until revision
384: .Ar rev .
385: .It rev:
386: Delete all revisions of the branch from revision
387: .Ar rev
388: until the last revision of the branch.
389: .El
390: .It Fl q
391: Quiet mode.
392: .It Xo Fl s
393: .Ar state Ns Op : Ns Ar rev
394: .Xc
395: Change state of a revision.
396: If the revision is not specified, the last revision of the default
397: branch changes state.
398: The
399: .Ic state
400: is a string of characters of your choice.
401: The state of a revision can be modified without having to
402: .Ic commit
403: a new revision.
404: The default
405: .Ic state
406: is
407: .Sq Exp
408: (Experimental).
409: For instance, you could also use
410: .Sq Dev
411: or
412: .Sq Reviewed .
413: .It Fl t Ar file \*(Ba Ar str
414: Change the descriptive text.
415: The descriptive text is taken from the
416: .Ar file
417: specified as argument or from the string
418: .Ar str
419: given as argument if it is preceded by the
420: .Sq -
421: character.
422: If no argument is used, the descriptive text is taken from standard input.
423: .El
1.13 jmc 424: .Pp
425: Aliases:
426: .Ic adm ,
427: .Ic rcs .
1.91 jmc 428: .Ss annotate
1.23 xsa 429: For each line of any files specified, show information about its
430: last revision.
431: The information given is the last revision when a modification occurred,
432: the author's name, and the date of the revision.
1.91 jmc 433: .Bd -literal -offset indent
434: Usage: cvs annotate [flR] [-D date | -r rev] [file ...]
435: .Ed
1.26 xsa 436: .Pp
437: The
1.35 jmc 438: .Ic annotate
439: command takes the following options:
440: .Bl -tag -width Ds -offset 3n
441: .It Fl D Ar date
442: Show the annotations as of the latest revision no later than
443: .Ar date .
444: .It Fl f
445: Force the use of the head revision if the specified
1.26 xsa 446: tag or date is not found.
447: This can be used in combination with
448: .Fl D
449: or
450: .Fl r
451: to ensure that there is some output from the
452: .Ic annotate
453: command, even if only to show Revision 1.1 of the file.
1.35 jmc 454: .It Fl l
455: Limit the scope of the search to the local directory
456: only and disable recursive behaviour.
457: .It Fl R
458: Enable recursive behaviour.
459: This is the default.
460: .It Fl r Ar rev
461: Show annotations as of revision
1.26 xsa 462: .Ar rev
463: (can be a revision number or a tag).
1.35 jmc 464: .El
1.13 jmc 465: .Pp
466: Aliases:
1.66 jfb 467: .Ic ann ,
468: .Ic blame .
1.91 jmc 469: .Ss checkout
1.7 jfb 470: The
1.11 jmc 471: .Ic checkout
1.7 jfb 472: command is used to create a local copy of one or more modules present on the
473: target CVS repository.
1.91 jmc 474: .Bd -literal -offset indent
475: Usage: cvs checkout [-AcflNnPpRs] [-d dir] [-j rev] [-k mode]
476: -D date | -r rev module ...
477: .Ed
1.37 xsa 478: .Pp
479: The
480: .Ic checkout
481: command takes the following options:
482: .Bl -tag -width Ds -offset 3n
483: .It Fl A
1.41 xsa 484: Reset any sticky tags, dates, or keyword substitution modes that
485: have been set on the tree.
1.37 xsa 486: .It Fl c
487: Display the list of available modules.
488: .It Fl D Ar date
489: Check out as of the latest revision no later than
490: .Ar date
1.89 xsa 491: (implies
492: .Fl P )
1.37 xsa 493: (is sticky).
494: .It Fl d Ar dir
495: Check out in directory
496: .Ar dir
497: instead of the directory bearing the same name as the
498: .Ar module .
499: .It Fl f
500: Force the use of the head revision if the specified
501: tag or date is not found.
502: .It Fl j Ar rev
503: Merge in changes made between current revision and
504: .Ar rev .
505: If two
506: .Fl j
507: options are specified, only merge the differences between the two
508: revisions of the branch.
509: This allows successive merges without having to resolve
510: already resolved conflicts again.
511: .It Fl k Ar mode
512: Specify the keyword substitution mode (is sticky).
513: .It Fl l
514: Limit the scope of the search to the local directory
515: only and disable recursive behaviour.
516: .It Fl N
517: If used in conjunction with the
518: .Fl d
519: option, files are placed in local directory
520: .Ar module ,
521: located in directory
522: .Ar dir .
523: .It Fl n
524: Do not execute programs listed in the
525: .Pa CVSROOT/modules
526: file.
527: .It Fl P
528: Prune empty directories.
529: .It Fl p
530: Check out files to standard output (avoids stickiness).
531: .It Fl R
532: Enable recursive behaviour.
533: This is the default.
534: .It Fl r Ar rev
535: Check out from a particular revision or branch (implies
536: .Fl P )
537: (is sticky).
538: .It Fl s
539: Like
540: .Fl c ,
541: but include module status.
542: .El
1.13 jmc 543: .Pp
544: Aliases:
545: .Ic co ,
546: .Ic get .
1.91 jmc 547: .Ss commit
1.1 jfb 548: The
1.11 jmc 549: .Ic commit
1.1 jfb 550: command is used to send local changes back to the server and update the
551: repository's information to reflect the changes.
1.91 jmc 552: .Bd -literal -offset indent
553: Usage: cvs commit [-flnR] [-F logfile | -m msg] [-r rev] [file ...]
554: .Ed
1.27 xsa 555: .Pp
556: The
1.35 jmc 557: .Ic commit
558: command takes the following options:
559: .Bl -tag -width Ds -offset 3n
560: .It Fl F Ar logfile
561: Specify a
1.27 xsa 562: .Ar file
1.35 jmc 563: which contains the log message.
564: .It Fl f
565: Force a file to be committed, even though it is unchanged.
566: .It Fl l
567: Limit the scope of the search to the local directory
568: only and disable recursive behaviour.
569: .It Fl m Ar msg
570: Specify a log message on the command line (suppresses the editor invocation).
571: .It Fl n
572: Do not execute programs listed in the
573: .Pa CVSROOT/modules
574: file.
575: .It Fl R
576: Enable recursive behaviour.
577: This is the default.
578: .It Fl r Ar rev
579: Commit to a particular symbolic or numerical revision.
580: .El
1.13 jmc 581: .Pp
582: Aliases:
583: .Ic ci ,
584: .Ic com .
1.91 jmc 585: .Ss diff
1.3 jfb 586: The
1.11 jmc 587: .Ic diff
1.3 jfb 588: command is very similar to the
589: .Xr diff 1
1.5 jfb 590: program, except that the differential comparisons that it generates are
1.3 jfb 591: between local or remote revisions of files stored in the CVS repository.
1.91 jmc 592: .Bd -literal -offset indent
593: Usage: cvs diff [-cilNnpRu]
594: [[-D date1 | -r rev1] [-D date2 | -r rev2]]
595: [-k mode] [file ...]
596: .Ed
1.53 xsa 597: .Pp
598: The
599: .Ic diff
600: command takes the following options:
601: .Bl -tag -width Ds -offset 3n
602: .It Fl c
603: Produces a diff with three lines of context.
604: See
605: .Xr diff 1
606: for more information.
607: .It Xo Fl D Ar date1
608: .Op Fl D Ar date2
609: .Xc
610: Differences between the revision at
611: .Ar date1
612: and the working copy or
613: .Ar date1
614: and
615: .Ar date2
616: (if specified).
617: .It Fl i
618: Ignore the case of letters.
619: For example,
620: .Sq A
621: will compare equal to
622: .Sq a .
623: .It Fl k Ar mode
624: Specify the keyword substitution mode.
625: .It Fl l
626: Limit the scope of the search to the local directory
627: only and disable recursive behaviour.
628: .It Fl N
629: Include added or removed files.
1.63 jfb 630: .It Fl n
631: Produces a diff in the same format as that used by
632: .Xr rcsdiff 1 ,
633: with a count of changed lines on each insert or delete command.
1.53 xsa 634: .It Fl p
635: With unified and context diffs, show with each change the first
636: 40 characters of the last line before the context beginning with
637: a letter, an underscore or a dollar sign.
638: See
639: .Xr diff 1
640: for more information.
641: .It Fl R
642: Enable recursive behaviour.
643: This is the default.
644: .It Xo Fl r Ar rev1
645: .Op Fl r Ar rev2
646: .Xc
647: Differences between revision
648: .Ar rev1
649: and the working copy or
650: .Ar rev1
651: and
652: .Ar rev2
653: (if specified).
654: .It Fl u
655: Produces a unified diff with three lines of context.
656: See
657: .Xr diff 1
658: for more information.
659: .El
1.13 jmc 660: .Pp
661: Aliases:
662: .Ic di ,
663: .Ic dif .
1.91 jmc 664: .Ss edit
1.30 xsa 665: The
666: .Ic edit
1.35 jmc 667: command is used to make a file that is being watched
668: (and therefore read-only)
1.30 xsa 669: readable and writable and to inform others that you are planning to edit it.
670: Notifications terminate when the
671: .Ic commit
672: command is issued.
673: Editing rights on the file can be given up using the
674: .Ic unedit
1.35 jmc 675: command, which terminates the temporary notifications.
1.91 jmc 676: .Bd -literal -offset indent
677: Usage: cvs edit [-lR] [-a action] [file ...]
678: .Ed
1.30 xsa 679: .Pp
680: The
1.35 jmc 681: .Ic edit
682: command takes the following options:
683: .Bl -tag -width Ds -offset 3n
684: .It Fl a Ar action
685: Specify the temporary notification wanted:
686: .Pp
1.61 deraadt 687: .Bl -tag -width Ds -compact
1.30 xsa 688: .It Cm commit
1.35 jmc 689: Another user has committed changes to the file.
1.30 xsa 690: .It Cm edit
691: Another user has issued the
692: .Ic edit
1.35 jmc 693: command on the file.
1.30 xsa 694: .It Cm unedit
695: Another user has issued the
696: .Ic unedit
1.35 jmc 697: command on the file.
1.30 xsa 698: .It Cm all
699: All of the above.
700: .It Cm none
701: None of the above.
702: .El
703: .Pp
704: The
705: .Fl a
706: flag may appear more than once, or not at all.
707: If omitted, the action defaults to
1.31 jmc 708: .Cm all .
1.35 jmc 709: .It Fl l
710: Limit the scope of the search to the local directory
711: only and disable recursive behaviour.
712: .It Fl R
713: Enable recursive behaviour.
714: This is the default.
715: .El
1.91 jmc 716: .Ss editors
1.33 xsa 717: The
718: .Ic editors
719: command lists the users with edition rights on a file.
720: For that, pseudo-lock mode must be enabled (see the
721: .Ic watch
722: command).
723: The e-mail address of the user editing the file, the timestamp
724: when the edition first started, the host from where the edition
725: has been requested and the path to the edited file are listed.
1.91 jmc 726: .Bd -literal -offset indent
727: Usage: cvs editors [-lR] [file ...]
728: .Ed
1.33 xsa 729: .Pp
730: The
1.35 jmc 731: .Ic editors
732: command takes the following options:
733: .Bl -tag -width Ds -offset 3n
734: .It Fl l
735: Limit the scope of the search to the local directory
736: only and disable recursive behaviour.
737: .It Fl R
738: Enable recursive behaviour.
739: This is the default.
740: .El
1.91 jmc 741: .Ss export
1.36 xsa 742: The
743: .Ic export
744: command extracts a copy of
745: .Ar module
746: without including the directories used for management by
747: .Nm .
748: This eases production of a software release.
749: A date or a revision must be specified for the command to be valid,
750: which ensures that later extractions can be reproduced with the same
751: options as the release.
752: .Pp
753: The checked out module's files will be placed in a directory
754: bearing the same name as the checked out module, by default.
1.91 jmc 755: .Bd -literal -offset indent
756: Usage: cvs export [-flNnR] [-d dir] [-k mode]
757: -D date | -r rev module ...
758: .Ed
1.36 xsa 759: .Pp
760: The
761: .Ic export
762: command takes the following options:
763: .Bl -tag -width Ds -offset 3n
764: .It Fl D Ar date
765: Export as of the latest revision no later than
766: .Ar date .
767: .It Fl d Ar dir
768: Export in directory
769: .Ar dir
770: instead of the directory bearing the same name as the
771: .Ar module .
772: .It Fl f
773: Force the use of the head revision if the specified
774: tag or date is not found.
775: This can be used in combination with
776: .Fl D
777: or
778: .Fl r
779: to ensure that the
780: .Ic export
781: command is valid.
782: .It Fl k Ar mode
783: Specify the keyword substitution mode: the
784: .Fl k Ar v
785: option is often used to avoid substitution of keywords during
786: a release cycle.
787: However, be aware that it does not handle an export containing
788: binary files correctly.
789: .It Fl l
790: Limit the scope of the search to the local directory
791: only and disable recursive behaviour.
792: .It Fl N
793: If used in conjunction with the
794: .Fl d
795: option, files are placed in local directory
796: .Ar module ,
797: located in directory
798: .Ar dir .
799: .It Fl n
800: Do not execute programs listed in the
801: .Pa CVSROOT/modules
802: file.
803: .It Fl R
804: Enable recursive behaviour.
805: This is the default.
806: .It Fl r Ar rev
807: Export from a particular symbolic or numerical revision.
808: .El
1.13 jmc 809: .Pp
810: Aliases:
811: .Ic ex ,
812: .Ic exp .
1.91 jmc 813: .Ss history
1.49 xsa 814: The
815: .Ic history
816: command is used to display the history of actions done in the
817: base repository.
818: This functionality is only available if the
1.50 xsa 819: .Pa CVSROOT/history
1.49 xsa 820: file has been created.
821: Only the
822: .Ic checkout ,
823: .Ic commit ,
824: .Ic export ,
825: .Ic release ,
826: .Ic rtag ,
827: and
828: .Ic update
829: commands are logged into this file.
1.91 jmc 830: .Bd -literal -offset indent
831: Usage: cvs history [-aceloTw] [-b str] [-D date] [-f file]
832: [-m module] [-n module] [-p path] [-r rev]
833: [-t tag] [-u user] [-x ACEFGMORTUW] [-z tz]
834: [file ...]
835: .Ed
1.49 xsa 836: .Pp
837: The
838: .Ic history
839: command takes the following options:
840: .Bl -tag -width Ds -offset 3n
841: .It Fl a
842: Display records for all users.
843: By default, only records from the user issuing the
844: .Ic history
845: command are displayed.
846: .It Fl b Ar str
847: Display everything back to a record containing the string
848: .Ar str
849: in either the module name, the file name, or the repository path.
850: .It Fl c
851: Display the archived files
852: .Pf ( Ic commit
853: command).
854: .It Fl D Ar date
855: Report no later than
856: .Ar date .
857: .It Fl e
858: Select all records (same as
859: .Fl x
860: with all types).
861: .It Fl f Ar file
862: Display records related to
863: .Ar file .
864: .It Fl l
865: Show last checkouts of modules with the
866: .Ic checkout
867: command.
868: .It Fl m Ar module
869: Look for the
870: .Ar module
871: (can be used several times).
872: .It Fl n Ar module
873: Search into the
874: .Ar module .
875: .It Fl o
876: Report on modules checked out by users.
877: .It Fl p Ar path
878: Display records from the base repository being in the directory
879: specified by the
880: .Ar path .
881: .It Fl r Ar rev
882: Report for a particular revision (checks in the RCS file).
883: .It Fl t Ar tag
884: Report since tag record placed in the
1.50 xsa 885: .Pa CVSROOT/history
1.49 xsa 886: file by any user.
887: .It Fl T
888: Report on all tags.
889: .It Fl u Ar user
890: Report for a specified
891: .Ar user .
892: Can be used several times to match many users.
893: .It Fl w
894: Check that records match the current working directory.
895: .It Fl x Ar ACEFGMORTUW
896: Extract by a specific record type specified by a single letter.
897: They can be used in combination.
898: The available types are as follows:
1.61 deraadt 899: .Bl -tag -width Ds
1.49 xsa 900: .It A
901: A file has been added with the
902: .Ic add
903: command.
904: .It C
905: A merge has been done, but unresolved conflicts still remain.
906: .It E
907: Export.
908: .It F
909: Release.
910: .It G
911: A merge has been done without conflict.
912: .It M
913: A file has been modified (using the
914: .Ic commit
915: command).
916: .It O
917: Checkout.
918: .It R
919: A file has been removed with the
920: .Ic remove
921: command.
922: .It T
923: Rtag.
924: .It U
925: Normal update.
926: .It W
927: The file has been deleted from the directory because it does not
928: exist anymore in the base repository.
929: .El
930: .It Fl z Ar tz
931: Display records with time synchronized with the
932: .Ar timezone
933: passed as argument.
934: .El
935: .Pp
936: All records have the following five first columns:
937: .Pp
938: .Bl -dash -compact
939: .It
940: The record type (the
941: .Fl x
942: option).
943: .It
944: The date of the action.
945: .It
946: The time of the action.
947: .It
948: The time zone.
949: .It
950: The user who made the action.
951: .El
952: .Pp
1.51 xsa 953: The other columns vary depending on the command issued:
954: .Pp
955: For records coming from the
956: .Ic rtag
957: command, the additional columns are as follows:
958: .Bd -literal -offset indent
959: <module> [<tag>:<argument>] {<working directory>}
960: .Ed
961: .Pp
962: For records coming from the
963: .Ic checkout
964: and
965: .Ic export
966: commands, the additional columns are as follows:
967: .Bd -literal -offset indent
968: <request> <repository> =<module>= <working directory>
969: .Ed
970: .Pp
971: For records coming from the
972: .Ic release
973: command, the additional columns are as follows:
974: .Bd -literal -offset indent
975: =<module>= <working directory>
976: .Ed
977: .Pp
978: For records coming from the
979: .Ic commit
980: and
981: .Ic update
982: commands, the additional columns are as follows:
983: .Bd -literal -offset indent
984: <version> <file> <module> == <working directory>
985: .Ed
1.13 jmc 986: .Pp
987: Aliases:
988: .Ic hi ,
989: .Ic his .
1.91 jmc 990: .Ss import
1.13 jmc 991: Import sources into CVS using vendor branches.
1.22 jmc 992: .Pp
993: At least three arguments are required:
1.72 xsa 994: .Ar module
1.22 jmc 995: specifies the location of the sources to be imported;
996: .Ar vendortag
997: is a tag for the entire branch;
998: .Ar releasetag
999: is used to identify the files you created with
1.35 jmc 1000: .Ic cvs import .
1.91 jmc 1001: .Bd -literal -offset indent
1002: Usage: cvs import [-d] [-b branch] [-I ign] [-k mode] [-m msg]
1003: [-W spec] module vendortag releasetag
1004: .Ed
1.35 jmc 1005: .Pp
1006: The
1007: .Ic import
1008: command takes the following options:
1009: .Bl -tag -width Ds -offset 3n
1010: .It Fl b Ar branch
1011: Specify the first-level branch number.
1.78 xsa 1012: .It Fl d
1013: Use the file's last modification time as the timestamp for the
1014: initial revisions.
1.72 xsa 1015: .It Fl I Ar ign
1016: Ignore files specified by
1017: .Ar ign .
1018: This option can be used several times on the command line.
1019: To see all files, use the
1020: .Fl I Ar !\&
1021: specification.
1022: .It Fl k Ar mode
1023: Specify the keyword substitution mode (is sticky).
1.35 jmc 1024: .It Fl m Ar msg
1025: Specify the log message to send.
1.72 xsa 1026: .It Fl W Ar spec
1027: Wrappers specification line.
1.35 jmc 1028: .El
1.13 jmc 1029: .Pp
1030: Aliases:
1031: .Ic im ,
1032: .Ic imp .
1.91 jmc 1033: .Ss init
1.13 jmc 1034: Create a CVS repository if it doesn't exist.
1.91 jmc 1035: .Ss kserver
1.13 jmc 1036: Start a Kerberos authentication server.
1.91 jmc 1037: .Ss log
1.52 xsa 1038: The
1039: .Ic log
1040: command displays information on a
1041: .Ar file
1042: such as its different revisions, description, different tags,
1043: as well as the comments, dates, and authors of these revisions.
1044: By default, the
1045: .Ic log
1046: command displays all the available information; the options are only
1047: used to restrict the displayed information.
1.91 jmc 1048: .Bd -literal -offset indent
1049: Usage: cvs log [-bhlNRt] [-d dates] [-r revs] [-s state]
1050: [-w users] [file ...]
1051: .Ed
1.52 xsa 1052: .Pp
1053: The
1054: .Ic log
1055: command takes the following options:
1056: .Bl -tag -width Ds -offset 3n
1057: .It Fl b
1058: List revisions of the default branch only.
1059: .It Fl d Ar dates
1060: Specify revisions with dates matching the specification.
1061: The specification might be as follows:
1.61 deraadt 1062: .Bl -tag -width Ds
1.52 xsa 1063: .It D1>D2 or D2>D1
1064: Select all revisions between
1065: .Ar \&D1
1066: and
1067: .Ar D2 .
1068: .It <D or D>
1069: Select all revisions before
1070: .Ar D .
1071: .It >D or D<
1072: Select all revisions after
1073: .Ar D .
1074: .It D
1075: Select the latest revision before or equal to
1076: .Ar D .
1077: .El
1078: .Pp
1079: The
1080: .Sq \*(Gt
1081: and
1082: .Sq \*(Lt
1083: characters can be followed by the
1084: .Sq =
1085: character to imply an inclusive specification.
1086: Several specifications can be used by separating them with the
1087: .Sq \&;
1088: character.
1089: .It Fl h
1090: Print header only.
1091: .It Fl l
1092: Limit the scope of the search to the local directory only.
1093: .It Fl N
1094: Do not list tags.
1095: .It Fl R
1096: Print name of RCS file only.
1097: .It Fl r Ar revs
1098: Specify revision(s) to list:
1.61 deraadt 1099: .Bl -tag -width Ds
1.52 xsa 1100: .It REV1,REV2,...,
1101: A list of revisions is specified by separating names or numbers
1102: of revisions by the
1103: .Sq \&,
1104: character.
1105: .It REV1:REV2
1106: List all revisions between
1107: .Ar REV1
1108: and
1109: .Ar REV2
1110: (they must be on the same branch).
1111: .It :REV
1112: List all revisions since the beginning of the branch until
1113: .Ar REV
1114: included.
1115: .It REV:
1116: List all revisions of the branch beginning with
1117: .Ar REV .
1118: .It BRANCH
1119: List all revisions of a branch.
1120: .It BRANCH.
1121: List the latest revision of the branch
1122: .Ar BRANCH .
1123: .It BRANCH1:BRANCH2
1124: List all revisions of branches between
1125: .Ar BRANCH1
1126: and
1127: .Ar BRANCH2 .
1128: .El
1129: .Pp
1130: Without argument, the
1131: .Fl r
1132: option means the latest revision of the default branch.
1133: .It Fl s Ar state
1134: List revisions of the specified
1135: .Ar state
1136: only.
1137: Several states can be listed by separating them with the
1138: .Sq \&,
1139: character.
1140: .It Fl t
1141: Print header and description only.
1142: .It Fl w Ar users
1143: Do not list revisions made by specified
1144: .Ar users .
1145: Usernames should be separated by the
1146: .Sq \&,
1147: character.
1148: .El
1.13 jmc 1149: .Pp
1150: Aliases:
1151: .Ic lo .
1.91 jmc 1152: .Ss login
1.35 jmc 1153: Prompt for a password for an authenticating server.
1.91 jmc 1154: .Ss logout
1.35 jmc 1155: Remove an entry in
1156: .Pa .cvspass
1157: for a remote repository.
1.91 jmc 1158: .Ss rdiff
1.55 xsa 1159: The
1160: .Ic rdiff
1161: command lists differences between two revisions in a
1.13 jmc 1162: .Xr patch 1
1.55 xsa 1163: compatible format.
1164: This command does not need a local checkout of the repository
1165: to work.
1.91 jmc 1166: .Bd -literal -offset indent
1167: Usage: cvs rdiff [-flR] [-c | -u] [-s | -t] [-V ver]
1168: -D date | -r rev [-D date2 | -r rev2]
1169: module ...
1170: .Ed
1.55 xsa 1171: .Pp
1172: The
1173: .Ic rdiff
1174: command takes the following options:
1175: .Bl -tag -width Ds -offset 3n
1176: .It Fl c
1177: Produces a diff with three lines of context.
1178: See
1179: .Xr diff 1
1180: for more information.
1181: This is the default.
1182: .It Xo Fl D Ar date
1183: .Op Fl D Ar date2
1184: .Xc
1185: Differences between the revision at
1186: .Ar date
1187: and the working copy or
1188: .Ar date
1189: and
1190: .Ar date2
1191: (if specified).
1192: .It Fl f
1193: Force the use of the head revision if the specified
1194: date or revision is not found.
1195: .It Fl l
1196: Limit the scope of the search to the local directory
1197: only and disable recursive behaviour.
1198: .It Fl R
1199: Enable recursive behaviour.
1200: This is the default.
1201: .It Xo Fl r Ar rev
1202: .Op Fl r Ar rev2
1203: .Xc
1204: Differences between revision
1205: .Ar rev
1206: and the working copy or
1207: .Ar rev
1208: and
1209: .Ar rev2
1210: (if specified).
1211: .It Fl s
1212: Create a summary change instead of a whole patch.
1213: .It Fl t
1214: Lists differences between the last two revisions of each file.
1215: .It Fl u
1216: Produces a diff in unidiff format.
1217: .It Fl V Ar ver
1218: Use the RCS version
1219: .Ar ver
1220: for keyword substitution.
1221: .El
1222: .Pp
1223: Aliases:
1224: .Ic pa ,
1225: .Ic patch .
1.91 jmc 1226: .Ss release
1.39 xsa 1227: The
1228: .Ic release
1229: command indicates to
1230: .Nm
1231: that the working copy of a module is no longer in use and checks
1232: that non archived modifications in the base repository do exist.
1233: This command is not mandatory.
1234: Local directories could always be removed without using it, but
1235: in this case the handling of history information will no longer be
1236: correct (see the
1237: .Ic history
1238: command).
1.91 jmc 1239: .Bd -literal -offset indent
1240: Usage: cvs release [-d] dir ...
1241: .Ed
1.39 xsa 1242: .Pp
1243: The
1244: .Ic release
1245: command takes the following options:
1246: .Bl -tag -width Ds -offset 3n
1247: .It Fl d Ar dir
1248: Remove the directory
1249: .Ar dir .
1250: Be aware that this option silently removes any directories that have
1251: been added to the local working copy without using the
1252: .Ic add
1253: command.
1254: .El
1255: .Pp
1256: For each file not being synchronized with the base repository,
1257: a single letter prefix is given to specify the state of the file.
1258: The possible prefixes are as follows:
1.61 deraadt 1259: .Bl -tag -width Ds
1.39 xsa 1260: .It \&?
1261: The file is unknown to
1262: .Nm
1263: and is not in the list of files to ignore.
1264: Any new directories which have not been added with the
1265: .Ic add
1266: command are silently ignored as well as their content.
1267: .It A
1268: The file has been added with the
1269: .Ic add
1270: command, but has not been committed to the repository with the
1271: .Ic commit
1272: command.
1273: .It M
1274: The file has been locally modified; a more recent version might
1275: exist in the base repository.
1276: .It R
1277: The file has been removed with the
1278: .Ic remove
1279: command, but has not been committed to the repository with the
1280: .Ic commit
1281: command.
1282: .It U
1283: A more recent version of the file does exist but it is not
1284: locally up to date.
1285: .El
1.40 xsa 1286: .Pp
1287: Aliases:
1288: .Ic re ,
1289: .Ic rel .
1.91 jmc 1290: .Ss remove
1.18 xsa 1291: The
1292: .Ic remove
1293: command is used to inform
1294: .Nm
1295: that
1296: .Ar file
1297: is scheduled to be removed from the repository.
1298: Files are not actually removed from the repository until the
1299: .Ic commit
1300: command has been run subsequently.
1.88 xsa 1301: .Pp
1302: There is no way to remove a directory with the
1303: .Ic remove
1304: command.
1305: .Nm
1306: will only remove a directory if it is empty and if the
1307: .Ic checkout
1308: or
1309: .Ic update
1310: commands are run with the
1311: .Fl P
1312: option.
1313: (Note that the
1314: .Ic export
1315: command always removes empty directories.)
1.91 jmc 1316: .Bd -literal -offset indent
1317: Usage: cvs remove [-flR] [file ...]
1318: .Ed
1.28 xsa 1319: .Pp
1320: The
1.35 jmc 1321: .Ic remove
1322: command takes the following options:
1323: .Bl -tag -width Ds -offset 3n
1324: .It Fl f
1325: Force local file removal.
1.28 xsa 1326: If this flag is not used, the file must be locally removed beforehand for
1327: the command to be valid.
1.35 jmc 1328: .It Fl l
1329: Limit the scope of the search to the local directory
1330: only and disable recursive behaviour.
1331: .It Fl R
1332: Enable recursive behaviour.
1333: This is the default.
1334: .El
1.18 xsa 1335: .Pp
1336: Aliases:
1.19 xsa 1337: .Ic rm ,
1338: .Ic delete .
1.91 jmc 1339: .Ss rlog
1.13 jmc 1340: Print out history information for a module.
1.91 jmc 1341: .Ss rtag
1.56 xsa 1342: The
1343: .Ic rtag
1344: command adds a symbolic tag to one or more modules.
1345: It is often used to create a new branch using the
1346: .Fl b
1347: option.
1.91 jmc 1348: .Bd -literal -offset indent
1349: Usage: cvs rtag [-abdFflnR] [-D date | -r rev]
1350: symbolic_tag module ...
1351: .Ed
1.56 xsa 1352: .Pp
1353: The
1354: .Ic rtag
1355: command takes the following options:
1356: .Bl -tag -width Ds -offset 3n
1357: .It Fl a
1358: Clear tag from files already removed with the
1359: .Ic remove
1360: command.
1361: .It Fl b
1362: Create a branch.
1363: .It Fl D Ar date
1364: Tag the most recent revision before
1365: .Ar date .
1366: .It Fl d
1367: Delete tag.
1368: .It Fl F
1369: Move tag if it already exists.
1370: If this option is not used and a tag is used a second time,
1371: .Nm
1372: will not execute the action.
1373: .It Fl f
1374: Force the use of the head revision if the specified
1375: revision or date is not found.
1376: .It Fl l
1377: Limit the scope of the search to the local directory
1378: only and disable recursive behaviour.
1379: .It Fl n
1380: Do not execute programs listed in the
1381: .Pa CVSROOT/modules
1382: file.
1383: .It Fl R
1384: Enable recursive behaviour.
1385: This is the default.
1386: .It Fl r Ar rev
1387: Tag at revision
1388: .Ar rev .
1389: .El
1390: .Pp
1391: Aliases:
1392: .Ic rt ,
1393: .Ic rfreeze .
1.91 jmc 1394: .Ss server
1.13 jmc 1395: Server mode.
1.91 jmc 1396: .Ss status
1.25 xsa 1397: The
1398: .Ic status
1399: command is used to display the state of checked out files.
1.91 jmc 1400: .Bd -literal -offset indent
1401: Usage: cvs status [-lRv] [file ...]
1402: .Ed
1.25 xsa 1403: .Pp
1404: The
1.35 jmc 1405: .Ic status
1406: command takes the following options:
1407: .Bl -tag -width Ds -offset 3n
1408: .It Fl l
1409: Limit the scope of the search to the local directory
1410: only and disable recursive behaviour.
1411: .It Fl R
1412: Enable recursive behaviour.
1413: This is the default.
1414: .It Fl v
1415: Display symbolic tags for
1416: .Ar file .
1.25 xsa 1417: .Pp
1.35 jmc 1418: The state may be one of the following:
1.61 deraadt 1419: .Bl -tag -width Ds
1.25 xsa 1420: .It Cm Locally Added
1421: The file has been added with the
1422: .Ic add
1423: command, but has not been committed to the repository with the
1424: .Ic commit
1425: command.
1426: .It Cm Locally Modified
1.35 jmc 1427: The file is up to date, but has been locally modified.
1.25 xsa 1428: .It Cm Locally Removed
1429: The file has been removed with the
1430: .Ic remove
1431: command, but has not been committed to the repository with the
1432: .Ic commit
1433: command.
1434: .It Cm Needs Checkout
1435: The file has not been modified; a new version is available.
1436: .It Cm Needs Merge
1437: The file has been modified and a newer version is available.
1438: .It Cm Needs Patch
1439: Same as
1440: .Ic Needs Checkout
1441: but, in client-server mode, only the differences are sent to save
1442: network resources.
1443: .It Cm Unresolved Conflict
1444: A merge has been done, but unresolved conflicts still remain.
1445: .It Cm Up-to-date
1446: The file is up to date.
1447: .El
1.35 jmc 1448: .El
1.13 jmc 1449: .Pp
1450: Aliases:
1451: .Ic st ,
1452: .Ic stat .
1.91 jmc 1453: .Ss tag
1.57 xsa 1454: The
1455: .Ic tag
1456: command adds a symbolic tag to a checked out version of one or more files.
1.91 jmc 1457: .Bd -literal -offset indent
1458: Usage: cvs tag [-bcdFflR] [-D date | -r rev] [symbolic_tag]
1459: [file ...]
1460: .Ed
1.21 jmc 1461: .Pp
1462: The
1.35 jmc 1463: .Ic tag
1464: command takes the following options:
1465: .Bl -tag -width Ds -offset 3n
1466: .It Fl b
1.57 xsa 1467: Create a branch.
1468: .It Fl c
1469: Check that working files are not modified.
1470: .It Fl D Ar date
1471: Tag the most recent revision before
1472: .Ar date .
1.35 jmc 1473: .It Fl d
1474: Delete tag.
1.57 xsa 1475: .It Fl F
1476: Move tag if it already exists.
1477: If this option is not used and a tag is used a second time,
1478: .Nm
1479: will not execute the action.
1480: .It Fl f
1481: Force the use of the head revision if the specified
1482: revision or date is not found.
1.35 jmc 1483: .It Fl l
1484: Limit the scope of the search to the local directory
1485: only and disable recursive behaviour.
1486: .It Fl R
1487: Enable recursive behaviour.
1488: This is the default.
1.57 xsa 1489: .It Fl r Ar rev
1490: Tag at revision
1491: .Ar rev .
1.35 jmc 1492: .El
1.13 jmc 1493: .Pp
1494: Aliases:
1495: .Ic ta ,
1496: .Ic freeze .
1.91 jmc 1497: .Ss unedit
1.30 xsa 1498: The
1499: .Ic unedit
1500: command is used to give up an edition on a file and thus cancel
1501: the wanted temporary notifications.
1502: If the file has been modified since the
1.13 jmc 1503: .Ic edit
1.30 xsa 1504: command has been issued,
1505: .Nm
1506: will ask if you want to go back to the previous version, and lose the
1507: modifications done on the file, or stay in edition mode on it.
1.91 jmc 1508: .Bd -literal -offset indent
1509: Usage: cvs unedit [-lR] [file ...]
1510: .Ed
1.30 xsa 1511: .Pp
1512: The
1.35 jmc 1513: .Ic unedit
1514: command takes the following options:
1515: .Bl -tag -width Ds -offset 3n
1516: .It Fl l
1517: Limit the scope of the search to the local directory
1518: only and disable recursive behaviour.
1519: .It Fl R
1520: Enable recursive behaviour.
1521: This is the default.
1522: .El
1.91 jmc 1523: .Ss update
1.3 jfb 1524: The
1.11 jmc 1525: .Ic update
1.17 david 1526: command is used to merge any of the changes that have occurred on the remote
1.3 jfb 1527: repository into the local one where the command was run.
1.91 jmc 1528: .Bd -literal -offset indent
1529: Usage: cvs update [-AdflPpR] [-D date | -r rev] [-I ign]
1530: [-j rev] [-k mode] [-W spec] [file ...]
1531: .Ed
1.3 jfb 1532: .Pp
1533: The
1.35 jmc 1534: .Ic update
1535: command takes the following options:
1536: .Bl -tag -width Ds -offset 3n
1537: .It Fl A
1.41 xsa 1538: Reset any sticky tags, dates, or keyword substitution modes that
1539: have been set on the tree.
1.38 xsa 1540: .It Fl D Ar date
1541: Update as of the latest revision no later than
1542: .Ar date
1543: (is sticky).
1544: .It Fl d
1545: Create any new directories.
1546: Without this option,
1547: .Nm
1548: does not create any new files sitting in these new directories
1549: added in the base repository since the last update of the working
1550: copy, or since the last update with the
1551: .Fl d
1552: option.
1553: .It Fl f
1554: Force the use of the head revision if the specified
1555: tag or date is not found.
1556: .It Fl I Ar ign
1557: Ignore files specified by
1558: .Ar ign .
1559: This option can be used several times on the command line.
1560: To see all files, use the
1561: .Fl I Ar !\&
1562: specification.
1563: .It Fl j Ar rev
1564: Merge in changes made between current revision and
1565: .Ar rev .
1566: If two
1567: .Fl j
1568: options are specified, only merge the differences between the two
1569: revisions of the branch.
1570: This allows successive merges without having to resolve
1571: already resolved conflicts again.
1572: .It Fl k Ar mode
1573: Specify the keyword substitution mode (is sticky).
1.35 jmc 1574: .It Fl l
1575: Limit the scope of the search to the local directory
1576: only and disable recursive behaviour.
1577: .It Fl P
1578: Prune any directories that have become empty as a result of the update.
1.38 xsa 1579: .It Fl p
1580: Send the result of the update to standard output (avoids stickiness).
1.35 jmc 1581: .It Fl R
1582: Enable recursive behaviour.
1583: This is the default.
1.38 xsa 1584: .It Fl r Ar rev
1585: Update from a particular revision or branch (is sticky).
1586: .It Fl W Ar spec
1587: Wrappers specification line.
1.35 jmc 1588: .El
1.38 xsa 1589: .Pp
1590: By default, the
1591: .Ic update
1592: command does not create new directories; the
1593: .Fl d
1594: option must be used for that.
1.29 xsa 1595: .Pp
1596: For each file updated, a single letter prefix is given to
1597: specify the state of the file.
1598: The possible prefixes are as follows:
1.61 deraadt 1599: .Bl -tag -width Ds
1.29 xsa 1600: .It \&?
1601: The file is unknown to
1602: .Nm .
1603: .It A
1604: The file has been added with the
1605: .Ic add
1606: command, but has not been committed to the repository with the
1607: .Ic commit
1608: command.
1609: .It C
1610: A merge, with a more recent version of the file, has been done,
1611: but unresolved conflicts still remain.
1612: .It M
1613: The file has been locally modified; if a more recent version
1614: is available, the merge has been done without conflict.
1615: .It P
1616: The same as
1617: .Sq U ,
1618: but, in client-server mode, only differences are sent to save network
1619: resources.
1620: .It R
1621: The file has been removed with the
1622: .Ic remove
1623: command, but has not been committed to the repository with the
1624: .Ic commit
1625: command.
1626: .It U
1627: The file is up to date.
1628: .El
1.13 jmc 1629: .Pp
1630: Aliases:
1631: .Ic up ,
1632: .Ic upd .
1.91 jmc 1633: .Ss version
1.3 jfb 1634: Causes
1635: .Nm
1636: to print its version information.
1.14 jfb 1637: If this command is issued within a local copy of a remote repository or
1638: if either the
1639: .Ev CVSROOT
1640: environment variable or the
1641: .Fl d
1642: flag specify a remote repository,
1.3 jfb 1643: .Nm
1644: will also connect to the server and ask it to print its version information.
1.13 jmc 1645: .Pp
1646: Aliases:
1647: .Ic ve ,
1648: .Ic ver .
1.91 jmc 1649: .Ss watch
1.32 xsa 1650: The
1651: .Ic watch
1652: command switches a file from normal mode to
1653: pseudo-lock mode as well as handling the notifications associated
1654: with it.
1655: Pseudo-lock mode means knowing who is editing a file:
1656: for that,
1657: .Nm
1658: extracts the file in read-only mode.
1659: Users must use the
1660: .Ic edit
1661: command to get the editing rights on the file.
1662: .Pp
1663: One of the following arguments to the
1664: .Ic watch
1665: command is mandatory: on, off, add, or remove.
1666: .Ar on
1667: switches the file into pseudo-lock mode;
1668: .Ar off
1669: switches it back to normal mode;
1670: .Ar add
1671: adds notifications for specific actions on the file;
1672: .Ar remove
1673: removes those notifications.
1674: .Pp
1675: The notifications are permanent.
1676: They remain in place until the
1677: .Ic watch remove
1678: command is issued while the temporary notifications are
1679: made available with the
1680: .Ic edit
1681: command.
1.91 jmc 1682: .Bd -literal -offset indent
1683: Usage: cvs watch on | off | add | remove [-lR] [-a action]
1684: [file ...]
1685: .Ed
1.32 xsa 1686: .Pp
1687: The
1.35 jmc 1688: .Ic watch
1689: command takes the following options:
1690: .Bl -tag -width Ds -offset 3n
1691: .It Fl a Ar action
1692: Specify the permanent notification wanted for
1.32 xsa 1693: .Ar add | remove :
1694: .Pp
1.61 deraadt 1695: .Bl -tag -width Ds -compact
1.32 xsa 1696: .It Cm commit
1.35 jmc 1697: Another user has committed changes to the file.
1.32 xsa 1698: .It Cm edit
1.35 jmc 1699: Another user is editing the file.
1.32 xsa 1700: .It Cm unedit
1.35 jmc 1701: Another user has finished editing the file.
1.32 xsa 1702: .It Cm all
1703: All of the above.
1704: .It Cm none
1705: No notification.
1706: .El
1707: .Pp
1.35 jmc 1708: If no specification is requested using the
1.32 xsa 1709: .Ar add
1710: or
1711: .Ar remove
1712: arguments, it implies the
1713: .Fl a Ar all
1714: option.
1.35 jmc 1715: .It Fl l
1716: Limit the scope of the search to the local directory
1717: only and disable recursive behaviour.
1718: .It Fl R
1719: Enable recursive behaviour.
1720: This is the default.
1721: .El
1.91 jmc 1722: .Ss watchers
1.32 xsa 1723: The
1724: .Ic watchers
1725: command lists the users who asked for notifications as well as the
1726: notifications details.
1727: The possible notifications are as follows:
1.61 deraadt 1728: .Bl -tag -width Ds
1.32 xsa 1729: .It Cm commit
1730: Permanent watch of a commit of a new version of a file.
1731: .It Cm edit
1732: Permanent watch of the start of file edition.
1733: .It Cm tcommit
1734: Temporary watch of a commit of new version of a file.
1735: .It Cm tedit
1736: Temporary watch of the start of file edition.
1737: .It Cm tunedit
1738: Temporary watch of the end of file edition.
1739: .It Cm unedit
1740: Permanent watch of the end of file edition.
1741: .El
1742: .Pp
1743: The temporary watches are set using the
1744: .Ic edit
1745: command, until the
1746: .Ic commit
1747: or
1748: .Ic unedit
1.35 jmc 1749: command is issued on a file.
1.91 jmc 1750: .Bd -literal -offset indent
1751: Usage: cvs watchers [-lR] [file ...]
1752: .Ed
1.35 jmc 1753: .Pp
1754: The
1755: .Ic watchers
1756: command takes the following options:
1757: .Bl -tag -width Ds -offset 3n
1758: .It Fl l
1759: Limit the scope of the search to the local directory
1760: only and disable recursive behaviour.
1761: .It Fl R
1762: Enable recursive behaviour.
1763: This is the default.
1.1 jfb 1764: .El
1765: .Sh ENVIRONMENT
1.61 deraadt 1766: .Bl -tag -width Ds
1.8 jmc 1767: .It Ev CVS_CLIENT_LOG
1768: This variable enables logging of all communications between the client and
1769: server when running in non-local mode.
1770: If set, this environment variable must contain a base path from which two
1771: paths will be generated by appending ".in" to the value for the server's
1772: input and ".out" for the server's output.
1.64 joris 1773: .Pp
1.65 joris 1774: The path can contain the following substitutes:
1775: .Pp
1776: .Bl -tag -width Ds -offset indent -compact
1.64 joris 1777: .It %c
1.65 joris 1778: the command being run
1.64 joris 1779: .It %d
1.65 joris 1780: the date
1781: .It %p
1782: the process ID
1.64 joris 1783: .It %u
1.65 joris 1784: the username of the person running it
1.64 joris 1785: .El
1786: .Pp
1787: The substitutes are only supported by OpenCVS.
1.1 jfb 1788: .It Ev CVS_RSH
1789: Name of the program to use when connecting to the server through a remote
1790: shell.
1791: The default is to use the
1792: .Xr ssh 1
1793: program.
1794: .It Ev CVS_SERVER
1795: If set, gives the name of the program to invoke as a
1796: .Nm
1797: server when using remote shell.
1798: The default is to use `cvs'.
1799: .It Ev CVSEDITOR
1800: Name of the editor to use when editing commit messages.
1.8 jmc 1801: Checked before
1802: .Ev EDITOR
1803: and
1804: .Ev VISUAL .
1.70 xsa 1805: .It Ev CVSREAD
1806: If set,
1807: .Nm
1808: extracts files in read-only mode.
1.8 jmc 1809: .It Ev CVSROOT
1810: When set, this variable should contain the string pointing to the root
1811: directory of the CVS repository.
1812: The contents of this variable are ignored when the
1813: .Fl d
1814: option is given or if `Root' files exist in the checked-out copy.
1.1 jfb 1815: .It Ev EDITOR
1.9 jmc 1816: Name of the editor to use when editing commit messages.
1817: This is traditionally a line-oriented editor,
1818: such as
1819: .Xr ex 1 .
1.74 xsa 1820: .It Ev HOME
1821: Directory where the
1822: .Pa .cvsignore
1823: and
1824: .Pa .cvsrc
1825: files are searched for.
1.77 xsa 1826: .It Ev TMPDIR
1.79 xsa 1827: When set, this variable specifies the directory where temporary files
1.77 xsa 1828: are to be created.
1829: The default is set to
1830: .Pa /tmp .
1.1 jfb 1831: .It Ev VISUAL
1.9 jmc 1832: Name of the editor to use when editing commit messages.
1833: This is traditionally a screen-oriented editor,
1834: such as
1835: .Xr vi 1 .
1.8 jmc 1836: .El
1837: .Sh FILES
1838: .Bl -tag -width Ds
1.75 xsa 1839: .It Pa $HOME/.cvsignore
1840: File containing a list of files (or
1841: .Xr sh 1
1842: file name patterns) that should be ignored by
1.76 jmc 1843: .Nm
1.75 xsa 1844: during the
1845: .Ic import ,
1846: .Ic release ,
1847: and
1848: .Ic update
1849: commands.
1.8 jmc 1850: .It Pa $HOME/.cvsrc
1851: File containing a list of implicit options to pass to certain commands.
1852: This file is read on startup unless the
1853: .Fl f
1854: option is specified.
1855: .It Pa $CVSROOT/CVSROOT
1856: Directory containing repository administrative files.
1.86 xsa 1857: .It Pa $CVSROOT/CVSROOT/history
1858: File containing reports of
1859: .Ic checkout ,
1860: .Ic commit ,
1861: .Ic export ,
1862: .Ic release ,
1863: .Ic rtag ,
1864: and
1865: .Ic update
1866: commands that have been issued.
1867: By default, the
1868: .Ic init
1869: command creates the
1870: .Pa history
1871: file.
1872: To disable history logging, the
1873: .Pa history
1874: file should be removed manually.
1875: The
1876: .Ic history
1877: command shows these reports according to several criteria.
1.8 jmc 1878: .It Pa $CVSROOT/CVSROOT/loginfo
1879: File containing associations between modules and handlers for
1880: post-commit logging.
1.85 xsa 1881: .El
1882: .Pp
1883: Each directory that is managed by
1884: .Nm
1885: contains a
1886: .Pa CVS
1887: directory.
1888: This directory is used by various
1889: .Nm
1890: commands to record the status of files in the current working directory.
1891: These files should not be modified manually by the user but by the
1892: .Nm
1893: commands instead.
1894: Files that are always stored in every
1895: .Pa CVS
1896: directory are as follows:
1897: .Bl -tag -width Ds
1898: .It Pa CVS/Entries
1899: File containing a list of files managed by
1900: .Nm .
1901: .Pa Entries
1902: has one line per file or directory describing the state of it with
1903: regard to the source repository.
1904: These lines have the following format:
1905: .Pp
1906: .Dl /name/revision/timestamp/options/tag
1907: .Bl -tag -width Ds
1908: .It name
1909: Name of the file in the directory.
1910: .It revision
1911: Revision of the file in the working directory.
1912: The revision is equal to
1913: .Sq 0
1914: if the file has been added with the
1915: .Ic add
1.87 jmc 1916: command or preceded by the
1.85 xsa 1917: .Sq -
1918: character if the file has been removed with the
1919: .Ic remove
1920: command.
1921: .It timestamp
1922: Contains the timestamp of the file at the time
1923: .Nm
1924: created it.
1925: If the timestamp is different from the actual modification time of the file,
1926: it means that the file has been modified.
1927: .It options
1928: Contains the keyword substitution mode used for this file.
1929: .It tag
1930: Contains
1931: .Sq T
1932: followed by a tagname or
1933: .Sq D
1934: followed by a date.
1935: .El
1936: .Pp
1937: Entries corresponding to directories have the following format:
1938: .Pp
1939: .Dl D/name////
1940: .Pp
1941: The lines in the
1942: .Pa Entries
1943: file can be in any order.
1944: .It Pa CVS/Repository
1945: File containing the path to the corresponding directory in the
1946: source repository.
1947: .It Pa CVS/Root
1948: File containing the value of the
1949: .Ev CVSROOT
1950: variable at the time of checkout.
1951: This file is used by all
1952: .Nm
1953: commands instead of
1954: .Ev CVSROOT
1955: once
1956: .Nm
1957: has checked for its existence.
1958: .El
1959: .Pp
1960: Depending on the circumstances, other files may exist in the
1961: .Pa CVS
1962: directory:
1963: .Bl -tag -width Ds
1964: .It Pa CVS/Base
1965: If pseudo-lock mode is enabled in client-server mode,
1966: the
1967: .Pa Base
1968: directory contains a copy of the file on which the
1969: .Ic edit
1970: command has been issued.
1971: This allows the
1972: .Ic unedit
1973: command to operate even if the CVS server is unreachable.
1974: .It Pa CVS/Baserev
1975: File listing the revisions for each file contained in the
1976: .Pa Base
1977: directory under the following format:
1978: .Pp
1979: .Dl name/revision/
1980: .It Pa CVS/Checkin.prog
1981: File containing the path to the command specified with the
1982: .Fl i
1983: option in the
1984: .Pa CVSROOT/modules
1985: file.
1986: .It Pa CVS/Entries.Static
1987: Tells
1988: .Nm
1989: to not add files to the directory unless the
1990: .Ic update
1991: command is issued with the
1992: .Fl d
1993: option.
1994: .It Pa CVS/Notify
1995: File containing the notifications that could not be sent to the
1996: CVS server but will be sent at the next successful connection.
1997: .It Pa CVS/Tag
1998: File containing the symbolic revision that was used at checkout.
1.90 xsa 1999: The first character of the line is a single letter indicating the
2000: type of tag:
2001: .Sq D ,
2002: .Sq N ,
2003: or
1.92 jmc 2004: .Sq T ,
1.90 xsa 2005: for date, non-branch tag, or branch tag, respectively.
2006: The rest of the line is the tag or date itself.
2007: The
2008: .Pa Tag
2009: file should not be removed manually:
2010: instead, use
2011: .Dq update -A .
1.85 xsa 2012: .It Pa CVS/Update.prog
2013: File containing the path to the command specified with the
2014: .Fl u
2015: option in the
2016: .Pa CVSROOT/modules
2017: file.
2018: .It Pa CVS/<name>,t
2019: File containing the description of the file
2020: .Pa file
2021: that has been added with the
2022: .Ic add
2023: command.
2024: This description is used by
2025: .Nm
2026: when archiving this file with the
2027: .Ic commit
2028: command.
1.81 xsa 2029: .El
2030: .Sh DIAGNOSTICS
2031: The
2032: .Nm
2033: utility exits 0 on success, or with one of the following return codes.
2034: The numerical values corresponding to the symbolic ones are given in
2035: parentheses for easy reference.
2036: .Bl -tag -width Ds
2037: .It Dv CVS_EX_USAGE Pq 1
2038: The
2039: .Nm
2040: command was used incorrectly.
2041: Either with the wrong number of arguments, a bad flag, a bad syntax in
2042: a parameter, etc...
2043: .It Dv CVS_EX_DATA Pq 2
2044: The input data was incorrect in some way.
2045: .It Dv CVS_EX_PROTO Pq 3
2046: The remote system returned something that was not possible during
2047: a protocol exchange.
2048: .It Dv CVS_EX_FILE Pq 4
2049: An error occurred while doing an operation on a file.
1.93 ! xsa 2050: .It Dv CVS_EX_BADROOT Pq 5
1.81 xsa 2051: The
2052: .Ev CVSROOT
2053: was not given or does not match the expected format.
1.1 jfb 2054: .El
2055: .Sh SEE ALSO
2056: .Xr diff 1 ,
1.15 jmc 2057: .Xr gzip 1 ,
1.1 jfb 2058: .Xr patch 1 ,
1.8 jmc 2059: .Xr rcs 1 ,
1.73 xsa 2060: .Xr cvsignore 5 ,
1.16 jmc 2061: .Xr cvsrc 5 ,
1.80 xsa 2062: .Xr cvswrappers 5 ,
1.62 xsa 2063: .Xr cvsintro 7
1.8 jmc 2064: .Sh HISTORY
2065: The OpenCVS project is a BSD-licensed rewrite of the original
2066: Concurrent Versioning System written by Jean-Francois Brousseau.
2067: The original CVS code was written in large parts by Dick Grune,
2068: Brian Berliner and Jeff Polk.
2069: .Sh AUTHORS
2070: .An Jean-Francois Brousseau
2071: .An Vincent Labrecque
2072: .An Joris Vink
1.43 jfb 2073: .An Xavier Santolaria
1.2 jfb 2074: .Sh CAVEATS
2075: This CVS implementation does not fully conform to the GNU CVS version.
1.3 jfb 2076: In some cases, this was done explicitly because GNU CVS has inconsistencies
1.2 jfb 2077: or ambiguous behaviour.
1.3 jfb 2078: Some things have also been left out or modified to enhance the overall
2079: security of the system.
2080: .Pp
2081: Among other things, support for the pserver connection mechanism has been
2082: dropped because of security issues with the authentication mechanism.