/contrib/cvs/doc/cvs.1
https://bitbucket.org/freebsd/freebsd-head/ · Unknown · 3968 lines · 3937 code · 31 blank · 0 comment · 0 complexity · 67448ebcc103d7fe3cc0c5d37422628d MD5 · raw file
Large files are truncated click here to view the full file
- .\" This is the man page for CVS. It is auto-generated from the
- .\" cvs.man.header, cvs.texinfo, & cvs.man.footer files. Please make changes
- .\" there. A full copyright & license notice may also be found in cvs.texinfo.
- .\"
- .\" Man page autogeneration, including this header file, is
- .\" Copyright 2004-2005 The Free Software Foundation, Inc.,
- .\" Derek R. Price, & Ximbiot <http://ximbiot.com>.
- .\"
- .\" This documentation is free software; you can redistribute it and/or modify
- .\" it under the terms of the GNU General Public License as published by
- .\" the Free Software Foundation; either version 2, or (at your option)
- .\" any later version.
- .\"
- .\" This documentation is distributed in the hope that it will be useful,
- .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
- .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- .\" GNU General Public License for more details.
- .\"
- .\" You should have received a copy of the GNU General Public License
- .\" along with this documentation; if not, write to the Free Software
- .\" Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- .de Id
- .ds Rv \\$3
- .ds Dt \\$4
- ..
- .TH CVS 1 "\*(Dt"
- .\" Full space in nroff; half space in troff
- .de SP
- .if n .sp
- .if t .sp .5
- ..
- .\" quoted command
- .de `
- .RB ` "\|\\$1\|" '\\$2
- ..
- .SH "NAME"
- cvs \- Concurrent Versions System
- .SH "SYNOPSIS"
- .TP
- \fBcvs\fP [ \fIcvs_options\fP ]
- .I cvs_command
- [
- .I command_options
- ] [
- .I command_args
- ]
- .SH "NOTE"
- .IX "revision control system" "\fLcvs\fR"
- .IX cvs "" "\fLcvs\fP \- concurrent versions system"
- .IX "concurrent versions system \- \fLcvs\fP"
- .IX "release control system" "cvs command" "" "\fLcvs\fP \- concurrent versions system"
- .IX "source control system" "cvs command" "" "\fLcvs\fP \- concurrent versions system"
- .IX revisions "cvs command" "" "\fLcvs\fP \- source control"
- This manpage is a summary of some of the features of
- \fBcvs\fP. It is auto-generated from an appendix of the CVS manual.
- For more in-depth documentation, please consult the
- Cederqvist manual (via the
- .B info CVS
- command or otherwise,
- as described in the SEE ALSO section of this manpage). Cross-references
- in this man page refer to nodes in the same.
- .SH "CVS commands"
- .SS "Guide to CVS commands"
- .SP
- This appendix describes the overall structure of
- \fBcvs\fR commands, and describes some commands in
- detail (others are described elsewhere; for a quick
- reference to \fBcvs\fR commands, see node `Invoking CVS\(aq in the CVS manual).
- .SP
- .SH "Structure"
- .SS "Overall structure of CVS commands"
- .IX "Structure"
- .IX "CVS command structure"
- .IX "Command structure"
- .IX "Format of CVS commands"
- .SP
- The overall format of all \fBcvs\fR commands is:
- .SP
- .PD 0
- .SP
- .IP "" 2
- cvs [ cvs_options ] cvs_command [ command_options ] [ command_args ]
- .PD
- .IP "" 0
- .SP
- .IP "" 0
- \fBcvs\fR
- .IP "" 2
- The name of the \fBcvs\fR program.
- .SP
- .IP "" 0
- \fBcvs_options\fR
- .IP "" 2
- Some options that affect all sub-commands of \fBcvs\fR. These are
- described below.
- .SP
- .IP "" 0
- \fBcvs_command\fR
- .IP "" 2
- One of several different sub-commands. Some of the commands have
- aliases that can be used instead; those aliases are noted in the
- reference manual for that command. There are only two situations
- where you may omit \fBcvs_command\fR: \fBcvs -H\fR elicits a
- list of available commands, and \fBcvs -v\fR displays version
- information on \fBcvs\fR itself.
- .SP
- .IP "" 0
- \fBcommand_options\fR
- .IP "" 2
- Options that are specific for the command.
- .SP
- .IP "" 0
- \fBcommand_args\fR
- .IP "" 2
- Arguments to the commands.
- .SP
- There is unfortunately some confusion between
- \fBcvs_options\fR and \fBcommand_options\fR.
- When given as a \fBcvs_option\fR, some options only
- affect some of the commands. When given as a
- \fBcommand_option\fR it may have a different meaning, and
- be accepted by more commands. In other words, do not
- take the above categorization too seriously. Look at
- the documentation instead.
- .SP
- .SH "Exit status"
- .SS "CVS\(aqs exit status"
- .IX "Exit status, of CVS"
- .SP
- \fBcvs\fR can indicate to the calling environment whether it
- succeeded or failed by setting its \fIexit status\fR.
- The exact way of testing the exit status will vary from
- one operating system to another. For example in a unix
- shell script the \fB$?\fR variable will be 0 if the
- last command returned a successful exit status, or
- greater than 0 if the exit status indicated failure.
- .SP
- If \fBcvs\fR is successful, it returns a successful status;
- if there is an error, it prints an error message and
- returns a failure status. The one exception to this is
- the \fBcvs diff\fR command. It will return a
- successful status if it found no differences, or a
- failure status if there were differences or if there
- was an error. Because this behavior provides no good
- way to detect errors, in the future it is possible that
- \fBcvs diff\fR will be changed to behave like the
- other \fBcvs\fR commands.
- .SP
- .SH "~/.cvsrc"
- .SS "Default options and the ~/.cvsrc file"
- .IX "\&.cvsrc file"
- .IX "Option defaults"
- .SP
- There are some \fBcommand_options\fR that are used so
- often that you might have set up an alias or some other
- means to make sure you always specify that option. One
- example (the one that drove the implementation of the
- \fB.cvsrc\fR support, actually) is that many people find the
- default output of the \fBdiff\fR command to be very
- hard to read, and that either context diffs or unidiffs
- are much easier to understand.
- .SP
- The \fB~/.cvsrc\fR file is a way that you can add
- default options to \fBcvs_commands\fR within cvs,
- instead of relying on aliases or other shell scripts.
- .SP
- The format of the \fB~/.cvsrc\fR file is simple. The
- file is searched for a line that begins with the same
- name as the \fBcvs_command\fR being executed. If a
- match is found, then the remainder of the line is split
- up (at whitespace characters) into separate options and
- added to the command arguments \fIbefore\fR any
- options from the command line.
- .SP
- If a command has two names (e.g., \fBcheckout\fR and
- \fBco\fR), the official name, not necessarily the one
- used on the command line, will be used to match against
- the file. So if this is the contents of the user\(aqs
- \fB~/.cvsrc\fR file:
- .SP
- .PD 0
- .SP
- .IP "" 2
- log -N
- .IP "" 2
- diff -uN
- .IP "" 2
- rdiff -u
- .IP "" 2
- update -Pd
- .IP "" 2
- checkout -P
- .IP "" 2
- release -d
- .PD
- .IP "" 0
- .SP
- the command \fBcvs checkout foo\fR would have the
- \fB-P\fR option added to the arguments, as well as
- \fBcvs co foo\fR.
- .SP
- With the example file above, the output from \fBcvs
- diff foobar\fR will be in unidiff format. \fBcvs diff
- -c foobar\fR will provide context diffs, as usual.
- Getting "old" format diffs would be slightly more
- complicated, because \fBdiff\fR doesn\(aqt have an option
- to specify use of the "old" format, so you would need
- \fBcvs -f diff foobar\fR.
- .SP
- In place of the command name you can use \fBcvs\fR to
- specify global options (see node `Global options\(aq in the CVS manual). For
- example the following line in \fB.cvsrc\fR
- .SP
- .PD 0
- .SP
- .IP "" 2
- cvs -z6
- .PD
- .IP "" 0
- .SP
- causes \fBcvs\fR to use compression level 6.
- .SP
- .SH "Global options"
- .IX "Options, global"
- .IX "Global options"
- .IX "Left-hand options"
- .SP
- The available \fBcvs_options\fR (that are given to the
- left of \fBcvs_command\fR) are:
- .SP
- .IP "" 0
- \fB--allow-root=\fIrootdir\fB\fR
- .IP "" 2
- Specify legal \fBcvsroot\fR directory. See
- `Password authentication server\(aq in the CVS manual.
- .SP
- .IX "Authentication, stream"
- .IX "Stream authentication"
- .IP "" 0
- \fB-a\fR
- .IP "" 2
- Authenticate all communication between the client and
- the server. Only has an effect on the \fBcvs\fR client.
- As of this writing, this is only implemented when using
- a GSSAPI connection (see node `GSSAPI authenticated\(aq in the CVS manual).
- Authentication prevents certain sorts of attacks
- involving hijacking the active \fBtcp\fR connection.
- Enabling authentication does not enable encryption.
- .SP
- .IX "RCSBIN, overriding"
- .IX "Overriding RCSBIN"
- .IP "" 0
- \fB-b \fIbindir\fB\fR
- .IP "" 2
- In \fBcvs\fR 1.9.18 and older, this specified that
- \fBrcs\fR programs are in the \fIbindir\fR directory.
- Current versions of \fBcvs\fR do not run \fBrcs\fR
- programs; for compatibility this option is accepted,
- but it does nothing.
- .SP
- .IX "TMPDIR, overriding"
- .IX "Overriding TMPDIR"
- .IP "" 0
- \fB-T \fItempdir\fB\fR
- .IP "" 2
- Use \fItempdir\fR as the directory where temporary files are
- located. Overrides the setting of the \fB$TMPDIR\fR environment
- variable and any precompiled directory. This parameter should be
- specified as an absolute pathname.
- (When running client/server, \fB-T\fR affects only the local process;
- specifying \fB-T\fR for the client has no effect on the server and
- vice versa.)
- .SP
- .IX "CVSROOT, overriding"
- .IX "Overriding CVSROOT"
- .IP "" 0
- \fB-d \fIcvs_root_directory\fB\fR
- .IP "" 2
- Use \fIcvs_root_directory\fR as the root directory
- pathname of the repository. Overrides the setting of
- the \fB$CVSROOT\fR environment variable. See `Repository\(aq in the CVS manual.
- .SP
- .IX "EDITOR, overriding"
- .IX "Overriding EDITOR"
- .IP "" 0
- \fB-e \fIeditor\fB\fR
- .IP "" 2
- Use \fIeditor\fR to enter revision log information. Overrides the
- setting of the \fB$CVSEDITOR\fR and \fB$EDITOR\fR
- environment variables. For more information, see
- `Committing your changes\(aq in the CVS manual.
- .SP
- .IP "" 0
- \fB-f\fR
- .IP "" 2
- Do not read the \fB~/.cvsrc\fR file. This
- option is most often used because of the
- non-orthogonality of the \fBcvs\fR option set. For
- example, the \fBcvs log\fR option \fB-N\fR (turn off
- display of tag names) does not have a corresponding
- option to turn the display on. So if you have
- \fB-N\fR in the \fB~/.cvsrc\fR entry for \fBlog\fR,
- you may need to use \fB-f\fR to show the tag names.
- .SP
- .IP "" 0
- \fB-H\fR
- .IP "" 2
- .IP "" 0
- \fB--help\fR
- .IP "" 2
- Display usage information about the specified \fBcvs_command\fR
- (but do not actually execute the command). If you don\(aqt specify
- a command name, \fBcvs -H\fR displays overall help for
- \fBcvs\fR, including a list of other help options.
- .SP
- .IX "Read-only mode"
- .IP "" 0
- \fB-n\fR
- .IP "" 2
- Do not change any files. Attempt to execute the
- \fBcvs_command\fR, but only to issue reports; do not remove,
- update, or merge any existing files, or create any new files.
- .SP
- Note that \fBcvs\fR will not necessarily produce exactly
- the same output as without \fB-n\fR. In some cases
- the output will be the same, but in other cases
- \fBcvs\fR will skip some of the processing that would
- have been required to produce the exact same output.
- .SP
- .IP "" 0
- \fB-Q\fR
- .IP "" 2
- Cause the command to be really quiet; the command will only
- generate output for serious problems.
- .SP
- .IP "" 0
- \fB-q\fR
- .IP "" 2
- Cause the command to be somewhat quiet; informational messages,
- such as reports of recursion through subdirectories, are
- suppressed.
- .SP
- .IX "Read-only files, and -r"
- .IP "" 0
- \fB-r\fR
- .IP "" 2
- Make new working files read-only. Same effect
- as if the \fB$CVSREAD\fR environment variable is set
- (see node `Environment variables\(aq in the CVS manual). The default is to
- make working files writable, unless watches are on
- (see node `Watches\(aq in the CVS manual).
- .SP
- .IP "" 0
- \fB-s \fIvariable\fB=\fIvalue\fB\fR
- .IP "" 2
- Set a user variable (see node `Variables\(aq in the CVS manual).
- .SP
- .IX "Trace"
- .IP "" 0
- \fB-t\fR
- .IP "" 2
- Trace program execution; display messages showing the steps of
- \fBcvs\fR activity. Particularly useful with \fB-n\fR to explore the
- potential impact of an unfamiliar command.
- .SP
- .IP "" 0
- \fB-v\fR
- .IP "" 2
- .IP "" 0
- \fB--version\fR
- .IP "" 2
- Display version and copyright information for \fBcvs\fR.
- .SP
- .IX "CVSREAD, overriding"
- .IX "Overriding CVSREAD"
- .IP "" 0
- \fB-w\fR
- .IP "" 2
- Make new working files read-write. Overrides the
- setting of the \fB$CVSREAD\fR environment variable.
- Files are created read-write by default, unless \fB$CVSREAD\fR is
- set or \fB-r\fR is given.
- .SP
- .IP "" 0
- \fB-x\fR
- .IP "" 2
- .IX "Encryption"
- Encrypt all communication between the client and the
- server. Only has an effect on the \fBcvs\fR client. As
- of this writing, this is only implemented when using a
- GSSAPI connection (see node `GSSAPI authenticated\(aq in the CVS manual) or a
- Kerberos connection (see node `Kerberos authenticated\(aq in the CVS manual).
- Enabling encryption implies that message traffic is
- also authenticated. Encryption support is not
- available by default; it must be enabled using a
- special configure option, \fB--enable-encryption\fR,
- when you build \fBcvs\fR.
- .SP
- .IP "" 0
- \fB-z \fIgzip-level\fB\fR
- .IP "" 2
- .IX "Compression"
- .IX "Gzip"
- Set the compression level.
- Valid levels are 1 (high speed, low compression) to
- 9 (low speed, high compression), or 0 to disable
- compression (the default).
- Only has an effect on the \fBcvs\fR client.
- .SP
- .SP
- .SH "Common options"
- .SS "Common command options"
- .IX "Common options"
- .IX "Right-hand options"
- .SP
- This section describes the \fBcommand_options\fR that
- are available across several \fBcvs\fR commands. These
- options are always given to the right of
- \fBcvs_command\fR. Not all
- commands support all of these options; each option is
- only supported for commands where it makes sense.
- However, when a command has one of these options you
- can almost always count on the same behavior of the
- option as in other commands. (Other command options,
- which are listed with the individual commands, may have
- different behavior from one \fBcvs\fR command to the other).
- .SP
- \fBThe \fBhistory\fB command is an exception; it supports
- many options that conflict even with these standard options.\fR
- .SP
- .IX "Dates"
- .IX "Time"
- .IX "Specifying dates"
- .IP "" 0
- \fB-D \fIdate_spec\fB\fR
- .IP "" 2
- Use the most recent revision no later than \fIdate_spec\fR.
- \fIdate_spec\fR is a single argument, a date description
- specifying a date in the past.
- .SP
- The specification is \fIsticky\fR when you use it to make a
- private copy of a source file; that is, when you get a working
- file using \fB-D\fR, \fBcvs\fR records the date you specified, so that
- further updates in the same directory will use the same date
- (for more information on sticky tags/dates, see node `Sticky tags\(aq in the CVS manual).
- .SP
- \fB-D\fR is available with the \fBannotate\fR, \fBcheckout\fR,
- \fBdiff\fR, \fBexport\fR, \fBhistory\fR,
- \fBrdiff\fR, \fBrtag\fR, and \fBupdate\fR commands.
- (The \fBhistory\fR command uses this option in a
- slightly different way; see node `history options\(aq in the CVS manual).
- .SP
- .IX "Timezone, in input"
- .IX "Zone, time, in input"
- A wide variety of date formats are supported by
- \fBcvs\fR. The most standard ones are ISO8601 (from the
- International Standards Organization) and the Internet
- e-mail standard (specified in RFC822 as amended by
- RFC1123).
- .SP
- ISO8601 dates have many variants but a few examples
- are:
- .SP
- .PD 0
- .SP
- .IP "" 4
- 1972-09-24
- .IP "" 4
- 1972-09-24 20:05
- .PD
- .IP "" 2
- .SP
- There are a lot more ISO8601 date formats, and \fBcvs\fR
- accepts many of them, but you probably don\(aqt want to
- hear the \fIwhole\fR long story :-).
- .SP
- In addition to the dates allowed in Internet e-mail
- itself, \fBcvs\fR also allows some of the fields to be
- omitted. For example:
- .SP
- .PD 0
- .SP
- .IP "" 4
- 24 Sep 1972 20:05
- .IP "" 4
- 24 Sep
- .PD
- .IP "" 2
- .SP
- The date is interpreted as being in the
- local timezone, unless a specific timezone is
- specified.
- .SP
- These two date formats are preferred. However,
- \fBcvs\fR currently accepts a wide variety of other date
- formats. They are intentionally not documented here in
- any detail, and future versions of \fBcvs\fR might not
- accept all of them.
- .SP
- One such format is
- \fB\fImonth\fB/\fIday\fB/\fIyear\fB\fR. This may
- confuse people who are accustomed to having the month
- and day in the other order; \fB1/4/96\fR is January 4,
- not April 1.
- .SP
- Remember to quote the argument to the \fB-D\fR
- flag so that your shell doesn\(aqt interpret spaces as
- argument separators. A command using the \fB-D\fR
- flag can look like this:
- .SP
- .PD 0
- .SP
- .IP "" 4
- $ cvs diff -D "1 hour ago" cvs.texinfo
- .PD
- .IP "" 2
- .SP
- .IX "Forcing a tag match"
- .IP "" 0
- \fB-f\fR
- .IP "" 2
- When you specify a particular date or tag to \fBcvs\fR commands, they
- normally ignore files that do not contain the tag (or did not
- exist prior to the date) that you specified. Use the \fB-f\fR option
- if you want files retrieved even when there is no match for the
- tag or date. (The most recent revision of the file
- will be used).
- .SP
- Note that even with \fB-f\fR, a tag that you specify
- must exist (that is, in some file, not necessary in
- every file). This is so that \fBcvs\fR will continue to
- give an error if you mistype a tag name.
- .SP
- \fB-f\fR is available with these commands:
- \fBannotate\fR, \fBcheckout\fR, \fBexport\fR,
- \fBrdiff\fR, \fBrtag\fR, and \fBupdate\fR.
- .SP
- \fBWARNING: The \fBcommit\fB and \fBremove\fB
- commands also have a
- \fB-f\fB option, but it has a different behavior for
- those commands. See `commit options\(aq in the CVS manual, and
- `Removing files\(aq in the CVS manual.\fR
- .SP
- .IP "" 0
- \fB-k \fIkflag\fB\fR
- .IP "" 2
- Alter the default processing of keywords.
- See `Keyword substitution\(aq in the CVS manual, for the meaning of
- \fIkflag\fR. Your \fIkflag\fR specification is
- \fIsticky\fR when you use it to create a private copy
- of a source file; that is, when you use this option
- with the \fBcheckout\fR or \fBupdate\fR commands,
- \fBcvs\fR associates your selected \fIkflag\fR with the
- file, and continues to use it with future update
- commands on the same file until you specify otherwise.
- .SP
- The \fB-k\fR option is available with the \fBadd\fR,
- \fBcheckout\fR, \fBdiff\fR, \fBrdiff\fR, \fBimport\fR and
- \fBupdate\fR commands.
- .SP
- .IP "" 0
- \fB-l\fR
- .IP "" 2
- Local; run only in current working directory, rather than
- recursing through subdirectories.
- .SP
- Available with the following commands: \fBannotate\fR, \fBcheckout\fR,
- \fBcommit\fR, \fBdiff\fR, \fBedit\fR, \fBeditors\fR, \fBexport\fR,
- \fBlog\fR, \fBrdiff\fR, \fBremove\fR, \fBrtag\fR,
- \fBstatus\fR, \fBtag\fR, \fBunedit\fR, \fBupdate\fR, \fBwatch\fR,
- and \fBwatchers\fR.
- .SP
- .IX "Editor, avoiding invocation of"
- .IX "Avoiding editor invocation"
- .IP "" 0
- \fB-m \fImessage\fB\fR
- .IP "" 2
- Use \fImessage\fR as log information, instead of
- invoking an editor.
- .SP
- Available with the following commands: \fBadd\fR,
- \fBcommit\fR and \fBimport\fR.
- .SP
- .IP "" 0
- \fB-n\fR
- .IP "" 2
- Do not run any tag program. (A program can be
- specified to run in the modules
- database (see node `modules\(aq in the CVS manual); this option bypasses it).
- .SP
- \fBThis is not the same as the \fBcvs -n\fB
- program option, which you can specify to the left of a cvs command!\fR
- .SP
- Available with the \fBcheckout\fR, \fBexport\fR,
- and \fBrtag\fR commands.
- .SP
- .IP "" 0
- \fB-P\fR
- .IP "" 2
- Prune empty directories. See `Removing directories\(aq in the CVS manual.
- .SP
- .IP "" 0
- \fB-p\fR
- .IP "" 2
- Pipe the files retrieved from the repository to standard output,
- rather than writing them in the current directory. Available
- with the \fBcheckout\fR and \fBupdate\fR commands.
- .SP
- .IP "" 0
- \fB-R\fR
- .IP "" 2
- Process directories recursively. This is on by default.
- .SP
- Available with the following commands: \fBannotate\fR, \fBcheckout\fR,
- \fBcommit\fR, \fBdiff\fR, \fBedit\fR, \fBeditors\fR, \fBexport\fR,
- \fBrdiff\fR, \fBremove\fR, \fBrtag\fR,
- \fBstatus\fR, \fBtag\fR, \fBunedit\fR, \fBupdate\fR, \fBwatch\fR,
- and \fBwatchers\fR.
- .SP
- .IP "" 0
- \fB-r \fItag\fB\fR
- .IP "" 2
- .IX "HEAD, special tag"
- .IX "BASE, special tag"
- Use the revision specified by the \fItag\fR argument instead of the
- default \fIhead\fR revision. As well as arbitrary tags defined
- with the \fBtag\fR or \fBrtag\fR command, two special tags are
- always available: \fBHEAD\fR refers to the most recent version
- available in the repository, and \fBBASE\fR refers to the
- revision you last checked out into the current working directory.
- .SP
- The tag specification is sticky when you use this
- with \fBcheckout\fR or \fBupdate\fR to make your own
- copy of a file: \fBcvs\fR remembers the tag and continues to use it on
- future update commands, until you specify otherwise (for more information
- on sticky tags/dates, see node `Sticky tags\(aq in the CVS manual).
- .SP
- The tag can be either a symbolic or numeric tag, as
- described in `Tags\(aq in the CVS manual, or the name of a branch, as
- described in `Branching and merging\(aq in the CVS manual.
- When a command expects a specific revision,
- the name of a branch is interpreted as the most recent
- revision on that branch.
- .SP
- Specifying the \fB-q\fR global option along with the
- \fB-r\fR command option is often useful, to suppress
- the warning messages when the \fBrcs\fR file
- does not contain the specified tag.
- .SP
- \fBThis is not the same as the overall \fBcvs -r\fB option,
- which you can specify to the left of a \fBcvs\fB command!\fR
- .SP
- \fB-r\fR is available with the \fBannotate\fR, \fBcheckout\fR,
- \fBcommit\fR, \fBdiff\fR, \fBhistory\fR, \fBexport\fR, \fBrdiff\fR,
- \fBrtag\fR, and \fBupdate\fR commands.
- .SP
- .IP "" 0
- \fB-W\fR
- .IP "" 2
- Specify file names that should be filtered. You can
- use this option repeatedly. The spec can be a file
- name pattern of the same type that you can specify in
- the \fB.cvswrappers\fR file.
- Available with the following commands: \fBimport\fR,
- and \fBupdate\fR.
- .SP
- .SP
- .SH "add"
- .SS "Add files and directories to the repository"
- .IX "add (subcommand)"
- .SP
- .IP "\(bu" 2
- Synopsis: add [-k rcs-kflag] [-m message] files...
- .IP "\(bu" 2
- Requires: repository, working directory.
- .IP "\(bu" 2
- Changes: repository, working directory.
- .SP
- The \fBadd\fR command is used to present new files
- and directories for addition into the \fBcvs\fR
- repository. When \fBadd\fR is used on a directory,
- a new directory is created in the repository
- immediately. When used on a file, only the working
- directory is updated. Changes to the repository are
- not made until the \fBcommit\fR command is used on
- the newly added file.
- .SP
- The \fBadd\fR command also resurrects files that
- have been previously removed. This can be done
- before or after the \fBcommit\fR command is used
- to finalize the removal of files. Resurrected files
- are restored into the working directory at the time
- the \fBadd\fR command is executed.
- .SP
- .SH "add options"
- .SP
- These standard options are supported by \fBadd\fR
- (see node `Common options\(aq in the CVS manual, for a complete description of
- them):
- .SP
- .IP "" 0
- \fB-k \fIkflag\fB\fR
- .IP "" 2
- Process keywords according to \fIkflag\fR. See
- `Keyword substitution\(aq in the CVS manual.
- This option is sticky; future updates of
- this file in this working directory will use the same
- \fIkflag\fR. The \fBstatus\fR command can be viewed
- to see the sticky options. For more information on
- the \fBstatus\fR command, see node `Invoking CVS\(aq in the CVS manual.
- .SP
- .IP "" 0
- \fB-m \fImessage\fB\fR
- .IP "" 2
- Use \fImessage\fR as the log message, instead of
- invoking an editor.
- .SP
- .SH "add examples"
- .SP
- .SS "Adding a directory"
- .SP
- .PD 0
- .SP
- .IP "" 2
- $ mkdir doc
- .IP "" 2
- $ cvs add doc
- .IP "" 2
- Directory /path/to/repository/doc added to the repository
- .PD
- .IP "" 0
- .SP
- .SS "Adding a file"
- .SP
- .PD 0
- .SP
- .SP
- .IP "" 2
- $ >TODO
- .IP "" 2
- $ cvs add TODO
- .IP "" 2
- cvs add: scheduling file \`TODO\(aq for addition
- .IP "" 2
- cvs add: use \(aqcvs commit\(aq to add this file permanently
- .PD
- .IP "" 0
- .SP
- .SS "Undoing a \fBremove\fR command"
- .SP
- .PD 0
- .SP
- .IP "" 2
- $ rm -f makefile
- .IP "" 2
- $ cvs remove makefile
- .IP "" 2
- cvs remove: scheduling \`makefile\(aq for removal
- .IP "" 2
- cvs remove: use \(aqcvs commit\(aq to remove this file permanently
- .IP "" 2
- $ cvs add makefile
- .IP "" 2
- U makefile
- .IP "" 2
- cvs add: makefile, version 1.2, resurrected
- .PD
- .IP "" 0
- .SP
- .SH "admin"
- .SS "Administration"
- .IX "Admin (subcommand)"
- .SP
- .IP "\(bu" 2
- Requires: repository, working directory.
- .IP "\(bu" 2
- Changes: repository.
- .IP "\(bu" 2
- Synonym: rcs
- .SP
- This is the \fBcvs\fR interface to assorted
- administrative facilities. Some of them have
- questionable usefulness for \fBcvs\fR but exist for
- historical purposes. Some of the questionable options
- are likely to disappear in the future. This command
- \fIdoes\fR work recursively, so extreme care should be
- used.
- .SP
- .IX "cvsadmin"
- On unix, if there is a group named \fBcvsadmin\fR,
- only members of that group can run \fBcvs admin\fR
- (except for the \fBcvs admin -k\fR command, which can
- be run by anybody). This group should exist on the
- server, or any system running the non-client/server
- \fBcvs\fR. To disallow \fBcvs admin\fR for all users,
- create a group with no users in it. On NT, the
- \fBcvsadmin\fR feature does not exist and all users
- can run \fBcvs admin\fR.
- .SP
- .SH "admin options"
- .SP
- Some of these options have questionable usefulness for
- \fBcvs\fR but exist for historical purposes. Some even
- make it impossible to use \fBcvs\fR until you undo the
- effect!
- .SP
- .IP "" 0
- \fB-A\fIoldfile\fB\fR
- .IP "" 2
- Might not work together with \fBcvs\fR. Append the
- access list of \fIoldfile\fR to the access list of the
- \fBrcs\fR file.
- .SP
- .IP "" 0
- \fB-a\fIlogins\fB\fR
- .IP "" 2
- Might not work together with \fBcvs\fR. Append the
- login names appearing in the comma-separated list
- \fIlogins\fR to the access list of the \fBrcs\fR file.
- .SP
- .IP "" 0
- \fB-b[\fIrev\fB]\fR
- .IP "" 2
- Set the default branch to \fIrev\fR. In \fBcvs\fR, you
- normally do not manipulate default branches; sticky
- tags (see node `Sticky tags\(aq in the CVS manual) are a better way to decide
- which branch you want to work on. There is one reason
- to run \fBcvs admin -b\fR: to revert to the vendor\(aqs
- version when using vendor branches (see node `Reverting
- local changes\(aq in the CVS manual).
- There can be no space between \fB-b\fR and its argument.
- .SP
- .IX "Comment leader"
- .IP "" 0
- \fB-c\fIstring\fB\fR
- .IP "" 2
- Sets the comment leader to \fIstring\fR. The comment
- leader is not used by current versions of \fBcvs\fR or
- \fBrcs\fR 5.7. Therefore, you can almost surely not
- worry about it. See `Keyword substitution\(aq in the CVS manual.
- .SP
- .IP "" 0
- \fB-e[\fIlogins\fB]\fR
- .IP "" 2
- Might not work together with \fBcvs\fR. Erase the login
- names appearing in the comma-separated list
- \fIlogins\fR from the access list of the RCS file. If
- \fIlogins\fR is omitted, erase the entire access list.
- There can be no space between \fB-e\fR and its argument.
- .SP
- .IP "" 0
- \fB-I\fR
- .IP "" 2
- Run interactively, even if the standard input is not a
- terminal. This option does not work with the
- client/server \fBcvs\fR and is likely to disappear in
- a future release of \fBcvs\fR.
- .SP
- .IP "" 0
- \fB-i\fR
- .IP "" 2
- Useless with \fBcvs\fR. This creates and initializes a
- new \fBrcs\fR file, without depositing a revision. With
- \fBcvs\fR, add files with the \fBcvs add\fR command
- (see node `Adding files\(aq in the CVS manual).
- .SP
- .IP "" 0
- \fB-k\fIsubst\fB\fR
- .IP "" 2
- Set the default keyword
- substitution to \fIsubst\fR. See `Keyword
- substitution\(aq in the CVS manual. Giving an explicit \fB-k\fR option to
- \fBcvs update\fR, \fBcvs export\fR, or \fBcvs
- checkout\fR overrides this default.
- .SP
- .IP "" 0
- \fB-l[\fIrev\fB]\fR
- .IP "" 2
- Lock the revision with number \fIrev\fR. If a branch
- is given, lock the latest revision on that branch. If
- \fIrev\fR is omitted, lock the latest revision on the
- default branch. There can be no space between
- \fB-l\fR and its argument.
- .SP
- This can be used in conjunction with the
- \fBrcslock.pl\fR script in the \fBcontrib\fR
- directory of the \fBcvs\fR source distribution to
- provide reserved checkouts (where only one user can be
- editing a given file at a time). See the comments in
- that file for details (and see the \fBREADME\fR file
- in that directory for disclaimers about the unsupported
- nature of contrib). According to comments in that
- file, locking must set to strict (which is the default).
- .SP
- .IP "" 0
- \fB-L\fR
- .IP "" 2
- Set locking to strict. Strict locking means that the
- owner of an RCS file is not exempt from locking for
- checkin. For use with \fBcvs\fR, strict locking must be
- set; see the discussion under the \fB-l\fR option above.
- .SP
- .IX "Changing a log message"
- .IX "Replacing a log message"
- .IX "Correcting a log message"
- .IX "Fixing a log message"
- .IX "Log message, correcting"
- .IP "" 0
- \fB-m\fIrev\fB:\fImsg\fB\fR
- .IP "" 2
- Replace the log message of revision \fIrev\fR with
- \fImsg\fR.
- .SP
- .IP "" 0
- \fB-N\fIname\fB[:[\fIrev\fB]]\fR
- .IP "" 2
- Act like \fB-n\fR, except override any previous
- assignment of \fIname\fR. For use with magic branches,
- see `Magic branch numbers\(aq in the CVS manual.
- .SP
- .IP "" 0
- \fB-n\fIname\fB[:[\fIrev\fB]]\fR
- .IP "" 2
- Associate the symbolic name \fIname\fR with the branch
- or revision \fIrev\fR. It is normally better to use
- \fBcvs tag\fR or \fBcvs rtag\fR instead. Delete the
- symbolic name if both \fB:\fR and \fIrev\fR are
- omitted; otherwise, print an error message if
- \fIname\fR is already associated with another number.
- If \fIrev\fR is symbolic, it is expanded before
- association. A \fIrev\fR consisting of a branch number
- followed by a \fB.\fR stands for the current latest
- revision in the branch. A \fB:\fR with an empty
- \fIrev\fR stands for the current latest revision on the
- default branch, normally the trunk. For example,
- \fBcvs admin -n\fIname\fB:\fR associates \fIname\fR with the
- current latest revision of all the RCS files;
- this contrasts with \fBcvs admin -n\fIname\fB:$\fR which
- associates \fIname\fR with the revision numbers
- extracted from keyword strings in the corresponding
- working files.
- .SP
- .IX "Deleting revisions"
- .IX "Outdating revisions"
- .IX "Saving space"
- .IP "" 0
- \fB-o\fIrange\fB\fR
- .IP "" 2
- Deletes (\fIoutdates\fR) the revisions given by
- \fIrange\fR.
- .SP
- Note that this command can be quite dangerous unless
- you know \fIexactly\fR what you are doing (for example
- see the warnings below about how the
- \fIrev1\fR:\fIrev2\fR syntax is confusing).
- .SP
- If you are short on disc this option might help you.
- But think twice before using it\(emthere is no way short
- of restoring the latest backup to undo this command!
- If you delete different revisions than you planned,
- either due to carelessness or (heaven forbid) a \fBcvs\fR
- bug, there is no opportunity to correct the error
- before the revisions are deleted. It probably would be
- a good idea to experiment on a copy of the repository
- first.
- .SP
- Specify \fIrange\fR in one of the following ways:
- .SP
- .IP "" 2
- \fB\fIrev1\fB::\fIrev2\fB\fR
- .IP "" 4
- Collapse all revisions between rev1 and rev2, so that
- \fBcvs\fR only stores the differences associated with going
- from rev1 to rev2, not intermediate steps. For
- example, after \fB-o 1.3::1.5\fR one can retrieve
- revision 1.3, revision 1.5, or the differences to get
- from 1.3 to 1.5, but not the revision 1.4, or the
- differences between 1.3 and 1.4. Other examples:
- \fB-o 1.3::1.4\fR and \fB-o 1.3::1.3\fR have no
- effect, because there are no intermediate revisions to
- remove.
- .SP
- .IP "" 2
- \fB::\fIrev\fB\fR
- .IP "" 4
- Collapse revisions between the beginning of the branch
- containing \fIrev\fR and \fIrev\fR itself. The
- branchpoint and \fIrev\fR are left intact. For
- example, \fB-o ::1.3.2.6\fR deletes revision 1.3.2.1,
- revision 1.3.2.5, and everything in between, but leaves
- 1.3 and 1.3.2.6 intact.
- .SP
- .IP "" 2
- \fB\fIrev\fB::\fR
- .IP "" 4
- Collapse revisions between \fIrev\fR and the end of the
- branch containing \fIrev\fR. Revision \fIrev\fR is
- left intact but the head revision is deleted.
- .SP
- .IP "" 2
- \fB\fIrev\fB\fR
- .IP "" 4
- Delete the revision \fIrev\fR. For example, \fB-o
- 1.3\fR is equivalent to \fB-o 1.2::1.4\fR.
- .SP
- .IP "" 2
- \fB\fIrev1\fB:\fIrev2\fB\fR
- .IP "" 4
- Delete the revisions from \fIrev1\fR to \fIrev2\fR,
- inclusive, on the same branch. One will not be able to
- retrieve \fIrev1\fR or \fIrev2\fR or any of the
- revisions in between. For example, the command
- \fBcvs admin -oR_1_01:R_1_02 \&.\fR is rarely useful.
- It means to delete revisions up to, and including, the
- tag R_1_02. But beware! If there are files that have not
- changed between R_1_02 and R_1_03 the file will have
- \fIthe same\fR numerical revision number assigned to
- the tags R_1_02 and R_1_03. So not only will it be
- impossible to retrieve R_1_02; R_1_03 will also have to
- be restored from the tapes! In most cases you want to
- specify \fIrev1\fR::\fIrev2\fR instead.
- .SP
- .IP "" 2
- \fB:\fIrev\fB\fR
- .IP "" 4
- Delete revisions from the beginning of the
- branch containing \fIrev\fR up to and including
- \fIrev\fR.
- .SP
- .IP "" 2
- \fB\fIrev\fB:\fR
- .IP "" 4
- Delete revisions from revision \fIrev\fR, including
- \fIrev\fR itself, to the end of the branch containing
- \fIrev\fR.
- .SP
- None of the revisions to be deleted may have
- branches or locks.
- .SP
- If any of the revisions to be deleted have symbolic
- names, and one specifies one of the \fB::\fR syntaxes,
- then \fBcvs\fR will give an error and not delete any
- revisions. If you really want to delete both the
- symbolic names and the revisions, first delete the
- symbolic names with \fBcvs tag -d\fR, then run
- \fBcvs admin -o\fR. If one specifies the
- non-\fB::\fR syntaxes, then \fBcvs\fR will delete the
- revisions but leave the symbolic names pointing to
- nonexistent revisions. This behavior is preserved for
- compatibility with previous versions of \fBcvs\fR, but
- because it isn\(aqt very useful, in the future it may
- change to be like the \fB::\fR case.
- .SP
- Due to the way \fBcvs\fR handles branches \fIrev\fR
- cannot be specified symbolically if it is a branch.
- See `Magic branch numbers\(aq in the CVS manual for an explanation.
- .SP
- Make sure that no-one has checked out a copy of the
- revision you outdate. Strange things will happen if he
- starts to edit it and tries to check it back in. For
- this reason, this option is not a good way to take back
- a bogus commit; commit a new revision undoing the bogus
- change instead (see node `Merging two revisions\(aq in the CVS manual).
- .SP
- .IP "" 0
- \fB-q\fR
- .IP "" 2
- Run quietly; do not print diagnostics.
- .SP
- .IP "" 0
- \fB-s\fIstate\fB[:\fIrev\fB]\fR
- .IP "" 2
- Useful with \fBcvs\fR. Set the state attribute of the
- revision \fIrev\fR to \fIstate\fR. If \fIrev\fR is a
- branch number, assume the latest revision on that
- branch. If \fIrev\fR is omitted, assume the latest
- revision on the default branch. Any identifier is
- acceptable for \fIstate\fR. A useful set of states is
- \fBExp\fR (for experimental), \fBStab\fR (for
- stable), and \fBRel\fR (for released). By default,
- the state of a new revision is set to \fBExp\fR when
- it is created. The state is visible in the output from
- \fIcvs log\fR (see node `log\(aq in the CVS manual), and in the
- \fB$\fP\fPLog$\fR and \fB$\fP\fPState$\fR keywords
- (see node `Keyword substitution\(aq in the CVS manual). Note that \fBcvs\fR
- uses the \fBdead\fR state for its own purposes (see node `Attic\(aq in the CVS manual); to
- take a file to or from the \fBdead\fR state use
- commands like \fBcvs remove\fR and \fBcvs add\fR
- (see node `Adding and removing\(aq in the CVS manual), not \fBcvs admin -s\fR.
- .SP
- .IP "" 0
- \fB-t[\fIfile\fB]\fR
- .IP "" 2
- Useful with \fBcvs\fR. Write descriptive text from the
- contents of the named \fIfile\fR into the RCS file,
- deleting the existing text. The \fIfile\fR pathname
- may not begin with \fB-\fR. The descriptive text can be seen in the
- output from \fBcvs log\fR (see node `log\(aq in the CVS manual).
- There can be no space between \fB-t\fR and its argument.
- .SP
- If \fIfile\fR is omitted,
- obtain the text from standard input, terminated by
- end-of-file or by a line containing \fB.\fR by itself.
- Prompt for the text if interaction is possible; see
- \fB-I\fR.
- .SP
- .IP "" 0
- \fB-t-\fIstring\fB\fR
- .IP "" 2
- Similar to \fB-t\fIfile\fB\fR. Write descriptive text
- from the \fIstring\fR into the \fBrcs\fR file, deleting
- the existing text.
- There can be no space between \fB-t\fR and its argument.
- .SP
- .IP "" 0
- \fB-U\fR
- .IP "" 2
- Set locking to non-strict. Non-strict locking means
- that the owner of a file need not lock a revision for
- checkin. For use with \fBcvs\fR, strict locking must be
- set; see the discussion under the \fB-l\fR option
- above.
- .SP
- .IP "" 0
- \fB-u[\fIrev\fB]\fR
- .IP "" 2
- See the option \fB-l\fR above, for a discussion of
- using this option with \fBcvs\fR. Unlock the revision
- with number \fIrev\fR. If a branch is given, unlock
- the latest revision on that branch. If \fIrev\fR is
- omitted, remove the latest lock held by the caller.
- Normally, only the locker of a revision may unlock it;
- somebody else unlocking a revision breaks the lock.
- This causes the original locker to be sent a \fBcommit\fR
- notification (see node `Getting Notified\(aq in the CVS manual).
- There can be no space between \fB-u\fR and its argument.
- .SP
- .IP "" 0
- \fB-V\fIn\fB\fR
- .IP "" 2
- In previous versions of \fBcvs\fR, this option meant to
- write an \fBrcs\fR file which would be acceptable to
- \fBrcs\fR version \fIn\fR, but it is now obsolete and
- specifying it will produce an error.
- .SP
- .IP "" 0
- \fB-x\fIsuffixes\fB\fR
- .IP "" 2
- In previous versions of \fBcvs\fR, this was documented
- as a way of specifying the names of the \fBrcs\fR
- files. However, \fBcvs\fR has always required that the
- \fBrcs\fR files used by \fBcvs\fR end in \fB,v\fR, so
- this option has never done anything useful.
- .SP
- .SP
- .SH "annotate"
- .SS "What revision modified each line of a file?"
- .IX "annotate (subcommand)"
- .SP
- .IP "\(bu" 2
- Synopsis: annotate [options] files\&...
- .IP "\(bu" 2
- Requires: repository.
- .IP "\(bu" 2
- Synonym: blame
- .IP "\(bu" 2
- Changes: nothing.
- .SP
- For each file in \fIfiles\fR, print the head revision
- of the trunk, together with information on the last
- modification for each line.
- .SP
- .SH "annotate options"
- .SP
- These standard options are supported by \fBannotate\fR
- (see node `Common options\(aq in the CVS manual for a complete description of
- them):
- .SP
- .IP "" 0
- \fB-l\fR
- .IP "" 2
- Local directory only, no recursion.
- .SP
- .IP "" 0
- \fB-R\fR
- .IP "" 2
- Process directories recursively.
- .SP
- .IP "" 0
- \fB-f\fR
- .IP "" 2
- Use head revision if tag/date not found.
- .SP
- .IP "" 0
- \fB-F\fR
- .IP "" 2
- Annotate binary files.
- .SP
- .IP "" 0
- \fB-r \fIrevision\fB\fR
- .IP "" 2
- Annotate file as of specified revision/tag.
- .SP
- .IP "" 0
- \fB-D \fIdate\fB\fR
- .IP "" 2
- Annotate file as of specified date.
- .SP
- .SH "annotate example"
- .SP
- For example:
- .SP
- .PD 0
- .SP
- .IP "" 2
- $ cvs annotate ssfile
- .IP "" 2
- Annotations for ssfile
- .IP "" 2
- ***************
- .IP "" 2
- 1.1 (mary 27-Mar-96): ssfile line 1
- .IP "" 2
- 1.2 (joe 28-Mar-96): ssfile line 2
- .PD
- .IP "" 0
- .SP
- The file \fBssfile\fR currently contains two lines.
- The \fBssfile line 1\fR line was checked in by
- \fBmary\fR on March 27. Then, on March 28, \fBjoe\fR
- added a line \fBssfile line 2\fR, without modifying
- the \fBssfile line 1\fR line. This report doesn\(aqt
- tell you anything about lines which have been deleted
- or replaced; you need to use \fBcvs diff\fR for that
- (see node `diff\(aq in the CVS manual).
- .SP
- The options to \fBcvs annotate\fR are listed in
- `Invoking CVS\(aq in the CVS manual, and can be used to select the files
- and revisions to annotate. The options are described
- in more detail there and in `Common options\(aq in the CVS manual.
- .SP
- .SH "checkout"
- .SS "Check out sources for editing"
- .IX "checkout (subcommand)"
- .IX "co (subcommand)"
- .SP
- .IP "\(bu" 2
- Synopsis: checkout [options] modules\&...
- .IP "\(bu" 2
- Requires: repository.
- .IP "\(bu" 2
- Changes: working directory.
- .IP "\(bu" 2
- Synonyms: co, get
- .SP
- Create or update a working directory containing copies of the
- source files specified by \fImodules\fR. You must execute
- \fBcheckout\fR before using most of the other \fBcvs\fR
- commands, since most of them operate on your working
- directory.
- .SP
- The \fImodules\fR are either
- symbolic names for some
- collection of source directories and files, or paths to
- directories or files in the repository. The symbolic
- names are defined in the \fBmodules\fR file.
- See `modules\(aq in the CVS manual.
- .SP
- Depending on the modules you specify, \fBcheckout\fR may
- recursively create directories and populate them with
- the appropriate source files. You can then edit these
- source files at any time (regardless of whether other
- software developers are editing their own copies of the
- sources); update them to include new changes applied by
- others to the source repository; or commit your work as
- a permanent change to the source repository.
- .SP
- Note that \fBcheckout\fR is used to create
- directories. The top-level directory created is always
- added to the directory where \fBcheckout\fR is
- invoked, and usually has the same name as the specified
- module. In the case of a module alias, the created
- sub-directory may have a different name, but you can be
- sure that it will be a sub-directory, and that
- \fBcheckout\fR will show the relative path leading to
- each file as it is extracted into your private work
- area (unless you specify the \fB-Q\fR global option).
- .SP
- The files created by \fBcheckout\fR are created
- read-write, unless the \fB-r\fR option to \fBcvs\fR
- (see node `Global options\(aq in the CVS manual) is specified, the
- \fBCVSREAD\fR environment variable is specified
- (see node `Environment variables\(aq in the CVS manual), or a watch is in
- effect for that file (see node `Watches\(aq in the CVS manual).
- .SP
- Note that running \fBcheckout\fR on a directory that was already
- built by a prior \fBcheckout\fR is also permitted.
- This is similar to specifying the \fB-d\fR option
- to the \fBupdate\fR command in the sense that new
- directories that have been created in the repository
- will appear in your work area.
- However, \fBcheckout\fR takes a module name whereas
- \fBupdate\fR takes a directory name. Also
- to use \fBcheckout\fR this way it must be run from the
- top level directory (where you originally ran
- \fBcheckout\fR from), so before you run
- \fBcheckout\fR to update an existing directory, don\(aqt
- forget to change your directory to the top level
- directory.
- .SP
- For the output produced by the \fBcheckout\fR command,
- see node `update output\(aq in the CVS manual.
- .SP
- .SH "checkout options"
- .SP
- These standard options are supported by \fBcheckout\fR
- (see node `Common options\(aq in the CVS manual for a complete description of
- them):
- .SP
- .IP "" 0
- \fB-D \fIdate\fB\fR
- .IP "" 2
- Use the most recent revision no later than \fIdate\fR.
- This option is sticky, and implies \fB-P\fR. See
- `Sticky tags\(aq in the CVS manual for more information on sticky tags/dates.
- .SP
- .IP "" 0
- \fB-f\fR
- .IP "" 2
- Only useful with the \fB-D \fIdate\fB\fR or \fB-r
- \fItag\fB\fR flags. If no matching revision is found,
- retrieve the most recent revision (instead of ignoring
- the file).
- .SP
- .IP "" 0
- \fB-k \fIkflag\fB\fR
- .IP "" 2
- Process keywords according to \fIkflag\fR. See
- `Keyword substitution\(aq in the CVS manual.
- This option is sticky; future updates of
- this file in this working directory will use the same
- \fIkflag\fR. The \fBstatus\fR command can be viewed
- to see the sticky options. See `Invoking CVS\(aq in the CVS manual for
- more information on the \fBstatus\fR command.
- .SP
- .IP "" 0
- \fB-l\fR
- .IP "" 2
- Local; run only in current working directory.
- .SP
- .IP "" 0
- \fB-n\fR
- .IP "" 2
- Do not run any checkout program (as specified
- with the \fB-o\fR option in the modules file;
- see node `modules\(aq in the CVS manual).
- .SP
- .IP "" 0
- \fB-P\fR
- .IP "" 2
- Prune empty directories. See `Moving directories\(aq in the CVS manual.
- .SP
- .IP "" 0
- \fB-p\fR
- .IP "" 2
- Pipe files to the standard output.
- .SP
- .IP "" 0
- \fB-R\fR
- .IP "" 2
- Checkout directories recursively. This option is on by default.
- .SP
- .IP "" 0
- \fB-r \fItag\fB\fR
- .IP "" 2
- Use revision \fItag\fR. This option is sticky, and implies \fB-P\fR.
- See `Sticky tags\(aq in the CVS manual, for more information on sticky tags/dates.
- .SP
- In addition to those, you can use these special command
- options with \fBcheckout\fR:
- .SP
- .IP "" 0
- \fB-A\fR
- .IP "" 2
- Reset any sticky tags, dates, or \fB-k\fR options.
- Does not reset sticky \fB-k\fR options on modified files.
- See `Sticky tags\(aq in the CVS manual for more information on sticky tags/dates.
- .SP
- .IP "" 0
- \fB-c\fR
- .IP "" 2
- Copy the module file, sorted, to the standard output,
- instead of creating or modifying any files or
- directories in your working directory.
- .SP
- .IP "" 0
- \fB-d \fIdir\fB\fR
- .IP "" 2
- Create a directory called \fIdir\fR for the working
- files, instead of using the module name. In general,
- using this flag is equivalent to using \fBmkdir
- \fIdir\fB; cd \fIdir\fB\fR followed by the checkout
- command without the \fB-d\fR flag.
- .SP
- There is an important exception, however. It is very
- convenient when checking out a single item to have the
- output appear in a directory that doesn\(aqt contain empty
- intermediate directories. In this case \fIonly\fR,
- \fBcvs\fR tries to \`\`shorten\(aq\(aq pathnames to avoid those empty
- directories.
- .SP
- For example, given a module \fBfoo\fR that contains
- the file \fBbar.c\fR, the command \fBcvs co -d dir
- foo\fR will create directory \fBdir\fR and place
- \fBbar.c\fR inside. Similarly, given a module
- \fBbar\fR which has subdirectory \fBbaz\fR wherein
- there is a file \fBquux.c\fR, the command \fBcvs co
- -d dir bar/baz\fR will create directory \fBdir\fR and
- place \fBquux.c\fR inside.
- .SP
- Using the \fB-N\fR flag will defeat this behavior.
- Given the same module definitions above, \fBcvs co
- -N -d dir foo\fR will create directories \fBdir/foo\fR
- and place \fBbar.c\fR inside, while \fBcvs co -N -d
- dir bar/baz\fR will create directories \fBdir/bar/baz\fR
- and place \fBquux.c\fR inside.
- .SP
- .IP "" 0
- \fB-j \fItag\fB\fR
- .IP "" 2
- With two \fB-j\fR options, merge changes from the
- revision specified with the first \fB-j\fR option to
- the revision specified with the second \fBj\fR option,
- into the working directory.
- .SP
- With one \fB-j\fR option, merge changes from the
- ancestor revision to the revision specified with the
- \fB-j\fR option, into the working directory. The
- ancestor revision is the common ancestor of the
- revision which the working directory is based on, and
- the revision specified in the \fB-j\fR option.
- .SP
- In addition, each -j option can contain an optional
- date specification which, when used with branches, can
- limit the chosen revision to one within a specific
- date. An optional date is specified by adding a colon
- (:) to the tag:
- \fB-j\fISymbolic_Tag\fB:\fIDate_Specifier\fB\fR.
- .SP
- See `Branching and merging\(aq in the CVS manual.
- .SP
- .IP "" 0
- \fB-N\fR
- .IP "" 2
- Only useful together with \fB-d \fIdir\fB\fR. With
- this option, \fBcvs\fR will not \`\`shorten\(aq\(aq module paths
- in your working directory when you check out a single
- module. See the \fB-d\fR flag for examples and a
- discussion.
- .SP
- .IP "" 0
- \fB-s\fR
- .IP "" 2
- Like \fB-c\fR, but include the status of all modules,
- and sort it by the status string. See `modules\(aq in the CVS manual, for
- info about the \fB-s\fR option that is used inside the
- modules file to set the module status.
- .SP
- .SH "checkout examples"
- .SP
- Get a copy of the module \fBtc\fR:
- .SP
- .PD 0
- .SP
- .IP "" 2
- $ cvs checkout tc
- .PD
- .IP "" 0
- .SP
- Get a copy of the module \fBtc\fR as it looked one day
- ago:
- .SP
- .PD 0
- .SP
- .IP "" 2
- $ cvs checkout -D yesterday tc
- .PD
- .IP "" 0
- .SP
- .SH "commit"
- .SS "Check files into the repository"
- .IX "commit (subcommand)"
- .SP
- .IP "\(bu" 2
- Synopsis: commit [-lRf] [-m \(aqlog_message\(aq |
- -F file] [-r revision] [files\&...]
- .IP "\(bu" 2
- Requires: working directory, repository.
- .IP "\(bu" 2
- Changes: repository.
- .IP "\(bu" 2
- Synonym: ci
- .SP
- Use \fBcommit\fR when you want to incorporate changes
- from your working source files into the source
- repository.
- .SP
- If you don\(aqt specify particular files to commit, all of
- the files in your working current directory are
- examined. \fBcommit\fR is careful to change in the
- repository only those files that you have really
- changed. By default (or if you explicitly specify the
- \fB-R\fR option), files in subdirectories are also
- examined and committed if they have changed; you can
- use the \fB-l\fR option to limit \fBcommit\fR to the
- current directory only.
- .SP
- \fBcommit\fR verifies that the selected files are up
- to date with the current revisions in the source
- repository; it will notify you, and exit without
- committing, if any of the specified files must be made
- current first with \fBupdate\fR (see node `update\(aq in the CVS manual).
- \fBcommit\fR does not call the \fBupdate\fR command
- for you, but rather leaves that for you to do when the
- time is right.
- .SP
- When all is well, an editor is invoked to allow you to
- enter a log message that will be written to one or more
- logging programs (see node `modules\(aq in the CVS manual, and see node `loginfo\(aq in the CVS manual)
- and placed in the \fBrcs\fR file inside the
- repository. This log message can be retrieved with the
- \fBlog\fR command; see node `log\(aq in the CVS manual. You can specify the
- log message on the command line with the \fB-m
- \fImessage\fB\fR option, and thus avoid the editor invocation,
- or use the \fB-F \fIfile\fB\fR option to specify
- that the argument file contains the log message.
- .SP
- .SH "commit options"
- .SP
- These standard options are supported by \fBcommit\fR
- (see node `Common options\(aq in the CVS manual for a complete description of
- them):
- .SP
- .IP "" 0
- \fB-l\fR
- .IP "" 2
- Local; run only in current working directory.
- .SP
- .IP "" 0
- \fB-R\fR
- .IP "" 2
- Commit directories recursively. This is on by default.
- .SP
- .IP "" 0
- \fB-r \fIrevision\fB\fR
- .IP "" 2
- Commit to \fIrevision\fR. \fIrevision\fR must be
- either a branch, or a revision on the main trunk that
- is higher than any existing revision number
- (see node `Assigning revisions\(aq in the CVS manual). You
- cannot commit to a specific revision on a branch.
- .SP
- \fBcommit\fR also supports these options:
- .SP
- .IP "" 0
- \fB-F \fIfile\fB\fR
- .IP "" 2
- Read the log message from \fIfile\fR, instead
- of invoking an editor.
- .SP
- .IP "" 0
- \fB-f\fR
- .IP "" 2
- Note that this is not the standard behavior of
- the \fB-f\fR option as defined in `Common options\(aq in the CVS manual.
- .SP
- Force \fBcvs\fR to commit a new revision even if you haven\(aqt
- made any changes to the file. If the current revision
- of \fIfile\fR is 1.7, then the following two commands
- are equivalent:
- .SP
- .PD 0
- .SP
- .IP "" 4
- $ cvs commit -f \fIfile\fR
- .IP "" 4
- $ cvs commit -r 1.8 \fIfile\fR
- .PD…