143c1707eStholoThis is cvs.info, produced by makeinfo version 4.0 from cvs.texinfo. 21e72d8d2Sderaadt 36407bc5bStholoSTART-INFO-DIR-ENTRY 46407bc5bStholo* CVS: (cvs). Concurrent Versions System 56407bc5bStholoEND-INFO-DIR-ENTRY 66407bc5bStholo 71e72d8d2Sderaadt Copyright (C) 1992, 1993 Signum Support AB Copyright (C) 1993, 1994 81e72d8d2SderaadtFree Software Foundation, Inc. 91e72d8d2Sderaadt 101e72d8d2Sderaadt Permission is granted to make and distribute verbatim copies of this 111e72d8d2Sderaadtmanual provided the copyright notice and this permission notice are 121e72d8d2Sderaadtpreserved on all copies. 131e72d8d2Sderaadt 141e72d8d2Sderaadt Permission is granted to copy and distribute modified versions of 151e72d8d2Sderaadtthis manual under the conditions for verbatim copying, provided also 166407bc5bStholothat the entire resulting derived work is distributed under the terms 176407bc5bStholoof a permission notice identical to this one. 181e72d8d2Sderaadt 191e72d8d2Sderaadt Permission is granted to copy and distribute translations of this 201e72d8d2Sderaadtmanual into another language, under the above conditions for modified 216407bc5bStholoversions, except that this permission notice may be stated in a 226407bc5bStholotranslation approved by the Free Software Foundation. 231e72d8d2Sderaadt 241e72d8d2Sderaadt 252f9d2fd9StholoFile: cvs.info, Node: First import, Next: Update imports, Up: Tracking sources 262f9d2fd9Stholo 272f9d2fd9StholoImporting for the first time 282f9d2fd9Stholo============================ 292f9d2fd9Stholo 302f9d2fd9Stholo Use the `import' command to check in the sources for the first time. 312f9d2fd9StholoWhen you use the `import' command to track third-party sources, the 322f9d2fd9Stholo"vendor tag" and "release tags" are useful. The "vendor tag" is a 332f9d2fd9Stholosymbolic name for the branch (which is always 1.1.1, unless you use the 3443c1707eStholo`-b BRANCH' flag--see *Note Multiple vendor branches::.). The "release 352f9d2fd9Stholotags" are symbolic names for a particular release, such as `FSF_0_04'. 362f9d2fd9Stholo 372f9d2fd9Stholo Note that `import' does _not_ change the directory in which you 382f9d2fd9Stholoinvoke it. In particular, it does not set up that directory as a CVS 392f9d2fd9Stholoworking directory; if you want to work with the sources import them 402f9d2fd9Stholofirst and then check them out into a different directory (*note Getting 41e77048c1Stholothe source::). 422f9d2fd9Stholo 432f9d2fd9Stholo Suppose you have the sources to a program called `wdiff' in a 442f9d2fd9Stholodirectory `wdiff-0.04', and are going to make private modifications 452f9d2fd9Stholothat you want to be able to use even when new releases are made in the 462f9d2fd9Stholofuture. You start by importing the source to your repository: 472f9d2fd9Stholo 482f9d2fd9Stholo $ cd wdiff-0.04 492f9d2fd9Stholo $ cvs import -m "Import of FSF v. 0.04" fsf/wdiff FSF_DIST WDIFF_0_04 502f9d2fd9Stholo 512f9d2fd9Stholo The vendor tag is named `FSF_DIST' in the above example, and the 522f9d2fd9Stholoonly release tag assigned is `WDIFF_0_04'. 532f9d2fd9Stholo 542f9d2fd9Stholo 552f9d2fd9StholoFile: cvs.info, Node: Update imports, Next: Reverting local changes, Prev: First import, Up: Tracking sources 562f9d2fd9Stholo 572f9d2fd9StholoUpdating with the import command 582f9d2fd9Stholo================================ 592f9d2fd9Stholo 602f9d2fd9Stholo When a new release of the source arrives, you import it into the 612f9d2fd9Stholorepository with the same `import' command that you used to set up the 622f9d2fd9Stholorepository in the first place. The only difference is that you specify 632f9d2fd9Stholoa different release tag this time. 642f9d2fd9Stholo 652f9d2fd9Stholo $ tar xfz wdiff-0.05.tar.gz 662f9d2fd9Stholo $ cd wdiff-0.05 672f9d2fd9Stholo $ cvs import -m "Import of FSF v. 0.05" fsf/wdiff FSF_DIST WDIFF_0_05 682f9d2fd9Stholo 692f9d2fd9Stholo For files that have not been modified locally, the newly created 702f9d2fd9Stholorevision becomes the head revision. If you have made local changes, 712f9d2fd9Stholo`import' will warn you that you must merge the changes into the main 722f9d2fd9Stholotrunk, and tell you to use `checkout -j' to do so. 732f9d2fd9Stholo 742f9d2fd9Stholo $ cvs checkout -jFSF_DIST:yesterday -jFSF_DIST wdiff 752f9d2fd9Stholo 762f9d2fd9StholoThe above command will check out the latest revision of `wdiff', 772f9d2fd9Stholomerging the changes made on the vendor branch `FSF_DIST' since 782f9d2fd9Stholoyesterday into the working copy. If any conflicts arise during the 792f9d2fd9Stholomerge they should be resolved in the normal way (*note Conflicts 80e77048c1Stholoexample::). Then, the modified files may be committed. 812f9d2fd9Stholo 822f9d2fd9Stholo Using a date, as suggested above, assumes that you do not import 832f9d2fd9Stholomore than one release of a product per day. If you do, you can always 842f9d2fd9Stholouse something like this instead: 852f9d2fd9Stholo 862f9d2fd9Stholo $ cvs checkout -jWDIFF_0_04 -jWDIFF_0_05 wdiff 872f9d2fd9Stholo 882f9d2fd9StholoIn this case, the two above commands are equivalent. 892f9d2fd9Stholo 902f9d2fd9Stholo 912f9d2fd9StholoFile: cvs.info, Node: Reverting local changes, Next: Binary files in imports, Prev: Update imports, Up: Tracking sources 922f9d2fd9Stholo 932f9d2fd9StholoReverting to the latest vendor release 942f9d2fd9Stholo====================================== 952f9d2fd9Stholo 962f9d2fd9Stholo You can also revert local changes completely and return to the 972f9d2fd9Sthololatest vendor release by changing the `head' revision back to the 982f9d2fd9Stholovendor branch on all files. For example, if you have a checked-out 992f9d2fd9Stholocopy of the sources in `~/work.d/wdiff', and you want to revert to the 1002f9d2fd9Stholovendor's version for all the files in that directory, you would type: 1012f9d2fd9Stholo 1022f9d2fd9Stholo $ cd ~/work.d/wdiff 1032f9d2fd9Stholo $ cvs admin -bWDIFF . 1042f9d2fd9Stholo 1052f9d2fd9StholoYou must specify the `-bWDIFF' without any space after the `-b'. *Note 1062f9d2fd9Stholoadmin options::. 1072f9d2fd9Stholo 1082f9d2fd9Stholo 1092f9d2fd9StholoFile: cvs.info, Node: Binary files in imports, Next: Keywords in imports, Prev: Reverting local changes, Up: Tracking sources 1102f9d2fd9Stholo 1112f9d2fd9StholoHow to handle binary files with cvs import 1122f9d2fd9Stholo========================================== 1132f9d2fd9Stholo 1142f9d2fd9Stholo Use the `-k' wrapper option to tell import which files are binary. 1152f9d2fd9Stholo*Note Wrappers::. 1162f9d2fd9Stholo 1172f9d2fd9Stholo 1182f9d2fd9StholoFile: cvs.info, Node: Keywords in imports, Next: Multiple vendor branches, Prev: Binary files in imports, Up: Tracking sources 1192f9d2fd9Stholo 1202f9d2fd9StholoHow to handle keyword substitution with cvs import 1212f9d2fd9Stholo================================================== 1222f9d2fd9Stholo 1232f9d2fd9Stholo The sources which you are importing may contain keywords (*note 124e77048c1StholoKeyword substitution::). For example, the vendor may use CVS or some 1252f9d2fd9Stholoother system which uses similar keyword expansion syntax. If you just 1262f9d2fd9Stholoimport the files in the default fashion, then the keyword expansions 1272f9d2fd9Stholosupplied by the vendor will be replaced by keyword expansions supplied 1282f9d2fd9Stholoby your own copy of CVS. It may be more convenient to maintain the 1292f9d2fd9Stholoexpansions supplied by the vendor, so that this information can supply 1302f9d2fd9Stholoinformation about the sources that you imported from the vendor. 1312f9d2fd9Stholo 1322f9d2fd9Stholo To maintain the keyword expansions supplied by the vendor, supply 1332f9d2fd9Stholothe `-ko' option to `cvs import' the first time you import the file. 1342f9d2fd9StholoThis will turn off keyword expansion for that file entirely, so if you 1352f9d2fd9Stholowant to be more selective you'll have to think about what you want and 1362f9d2fd9Stholouse the `-k' option to `cvs update' or `cvs admin' as appropriate. 1372f9d2fd9Stholo 1382f9d2fd9Stholo 1392f9d2fd9StholoFile: cvs.info, Node: Multiple vendor branches, Prev: Keywords in imports, Up: Tracking sources 1402f9d2fd9Stholo 1412f9d2fd9StholoMultiple vendor branches 1422f9d2fd9Stholo======================== 1432f9d2fd9Stholo 1442f9d2fd9Stholo All the examples so far assume that there is only one vendor from 1452f9d2fd9Stholowhich you are getting sources. In some situations you might get 1462f9d2fd9Stholosources from a variety of places. For example, suppose that you are 1472f9d2fd9Stholodealing with a project where many different people and teams are 1482f9d2fd9Stholomodifying the software. There are a variety of ways to handle this, 1492f9d2fd9Stholobut in some cases you have a bunch of source trees lying around and 1502f9d2fd9Stholowhat you want to do more than anything else is just to all put them in 1512f9d2fd9StholoCVS so that you at least have them in one place. 1522f9d2fd9Stholo 1532f9d2fd9Stholo For handling situations in which there may be more than one vendor, 1542f9d2fd9Stholoyou may specify the `-b' option to `cvs import'. It takes as an 1552f9d2fd9Stholoargument the vendor branch to import to. The default is `-b 1.1.1'. 1562f9d2fd9Stholo 1572f9d2fd9Stholo For example, suppose that there are two teams, the red team and the 1582f9d2fd9Stholoblue team, that are sending you sources. You want to import the red 1592f9d2fd9Stholoteam's efforts to branch 1.1.1 and use the vendor tag RED. You want to 1602f9d2fd9Stholoimport the blue team's efforts to branch 1.1.3 and use the vendor tag 1612f9d2fd9StholoBLUE. So the commands you might use are: 1622f9d2fd9Stholo 1632f9d2fd9Stholo $ cvs import dir RED RED_1-0 1642f9d2fd9Stholo $ cvs import -b 1.1.3 dir BLUE BLUE_1-5 1652f9d2fd9Stholo 1662f9d2fd9Stholo Note that if your vendor tag does not match your `-b' option, CVS 1672f9d2fd9Stholowill not detect this case! For example, 1682f9d2fd9Stholo 1692f9d2fd9Stholo $ cvs import -b 1.1.3 dir RED RED_1-0 1702f9d2fd9Stholo 1712f9d2fd9StholoBe careful; this kind of mismatch is sure to sow confusion or worse. I 1722f9d2fd9Stholocan't think of a useful purpose for the ability to specify a mismatch 1732f9d2fd9Stholohere, but if you discover such a use, don't. CVS is likely to make this 1742f9d2fd9Stholoan error in some future release. 1752f9d2fd9Stholo 1762f9d2fd9Stholo 1778506102dStholoFile: cvs.info, Node: Builds, Next: Special Files, Prev: Tracking sources, Up: Top 1788506102dStholo 1798506102dStholoHow your build system interacts with CVS 1808506102dStholo**************************************** 1818506102dStholo 1828506102dStholo As mentioned in the introduction, CVS does not contain software for 1838506102dStholobuilding your software from source code. This section describes how 1848506102dStholovarious aspects of your build system might interact with CVS. 1858506102dStholo 1868506102dStholo One common question, especially from people who are accustomed to 1878506102dStholoRCS, is how to make their build get an up to date copy of the sources. 1888506102dStholoThe answer to this with CVS is two-fold. First of all, since CVS 1898506102dStholoitself can recurse through directories, there is no need to modify your 1908506102dStholo`Makefile' (or whatever configuration file your build tool uses) to 1918506102dStholomake sure each file is up to date. Instead, just use two commands, 1928506102dStholofirst `cvs -q update' and then `make' or whatever the command is to 1932f9d2fd9Stholoinvoke your build tool. Secondly, you do not necessarily _want_ to get 1948506102dStholoa copy of a change someone else made until you have finished your own 1958506102dStholowork. One suggested approach is to first update your sources, then 1968506102dStholoimplement, build and test the change you were thinking of, and then 1978506102dStholocommit your sources (updating first if necessary). By periodically (in 1988506102dStholobetween changes, using the approach just described) updating your 1998506102dStholoentire tree, you ensure that your sources are sufficiently up to date. 2008506102dStholo 2018506102dStholo One common need is to record which versions of which source files 2028506102dStholowent into a particular build. This kind of functionality is sometimes 2038506102dStholocalled "bill of materials" or something similar. The best way to do 2048506102dStholothis with CVS is to use the `tag' command to record which versions went 205e77048c1Stholointo a given build (*note Tags::). 2068506102dStholo 2078506102dStholo Using CVS in the most straightforward manner possible, each 2088506102dStholodeveloper will have a copy of the entire source tree which is used in a 2098506102dStholoparticular build. If the source tree is small, or if developers are 2108506102dSthologeographically dispersed, this is the preferred solution. In fact one 2118506102dStholoapproach for larger projects is to break a project down into smaller 2128506102dStholoseparately-compiled subsystems, and arrange a way of releasing them 2138506102dStholointernally so that each developer need check out only those subsystems 2148506102dStholowhich are they are actively working on. 2158506102dStholo 2168506102dStholo Another approach is to set up a structure which allows developers to 2178506102dStholohave their own copies of some files, and for other files to access 2188506102dStholosource files from a central location. Many people have come up with 2198506102dStholosome such a system using features such as the symbolic link feature 2208506102dStholofound in many operating systems, or the `VPATH' feature found in many 2218506102dStholoversions of `make'. One build tool which is designed to help with this 2228506102dStholokind of thing is Odin (see 2238506102dStholo`ftp://ftp.cs.colorado.edu/pub/distribs/odin'). 2248506102dStholo 2258506102dStholo 2268506102dStholoFile: cvs.info, Node: Special Files, Next: CVS commands, Prev: Builds, Up: Top 2278506102dStholo 2288506102dStholoSpecial Files 2298506102dStholo************* 2308506102dStholo 2318506102dStholo In normal circumstances, CVS works only with regular files. Every 2328506102dStholofile in a project is assumed to be persistent; it must be possible to 2338506102dStholoopen, read and close them; and so on. CVS also ignores file 2348506102dStholopermissions and ownerships, leaving such issues to be resolved by the 2358506102dStholodeveloper at installation time. In other words, it is not possible to 2368506102dStholo"check in" a device into a repository; if the device file cannot be 2378506102dStholoopened, CVS will refuse to handle it. Files also lose their ownerships 2388506102dStholoand permissions during repository transactions. 2398506102dStholo 2408506102dStholo 2418506102dStholoFile: cvs.info, Node: CVS commands, Next: Invoking CVS, Prev: Special Files, Up: Top 2428506102dStholo 2438506102dStholoGuide to CVS commands 2448506102dStholo********************* 2458506102dStholo 2468506102dStholo This appendix describes the overall structure of CVS commands, and 2478506102dStholodescribes some commands in detail (others are described elsewhere; for 248e77048c1Stholoa quick reference to CVS commands, *note Invoking CVS::). 2498506102dStholo 2508506102dStholo* Menu: 2518506102dStholo 2528506102dStholo* Structure:: Overall structure of CVS commands 2538506102dStholo* Exit status:: Indicating CVS's success or failure 2548506102dStholo* ~/.cvsrc:: Default options with the ~/.csvrc file 2558506102dStholo* Global options:: Options you give to the left of cvs_command 2568506102dStholo* Common options:: Options you give to the right of cvs_command 2578506102dStholo* admin:: Administration 2588506102dStholo* checkout:: Checkout sources for editing 2598506102dStholo* commit:: Check files into the repository 2608506102dStholo* diff:: Show differences between revisions 2618506102dStholo* export:: Export sources from CVS, similar to checkout 2628506102dStholo* history:: Show status of files and users 2638506102dStholo* import:: Import sources into CVS, using vendor branches 2648506102dStholo* log:: Show log messages for files 2658506102dStholo* rdiff:: 'patch' format diffs between releases 2668506102dStholo* release:: Indicate that a directory is no longer in use 2678506102dStholo* update:: Bring work tree in sync with repository 2688506102dStholo 2698506102dStholo 2708506102dStholoFile: cvs.info, Node: Structure, Next: Exit status, Up: CVS commands 2718506102dStholo 2728506102dStholoOverall structure of CVS commands 2738506102dStholo================================= 2748506102dStholo 2758506102dStholo The overall format of all CVS commands is: 2768506102dStholo 2778506102dStholo cvs [ cvs_options ] cvs_command [ command_options ] [ command_args ] 2788506102dStholo 2798506102dStholo`cvs' 2808506102dStholo The name of the CVS program. 2818506102dStholo 2828506102dStholo`cvs_options' 2838506102dStholo Some options that affect all sub-commands of CVS. These are 2848506102dStholo described below. 2858506102dStholo 2868506102dStholo`cvs_command' 2878506102dStholo One of several different sub-commands. Some of the commands have 2888506102dStholo aliases that can be used instead; those aliases are noted in the 2898506102dStholo reference manual for that command. There are only two situations 2908506102dStholo where you may omit `cvs_command': `cvs -H' elicits a list of 2918506102dStholo available commands, and `cvs -v' displays version information on 2928506102dStholo CVS itself. 2938506102dStholo 2948506102dStholo`command_options' 2958506102dStholo Options that are specific for the command. 2968506102dStholo 2978506102dStholo`command_args' 2988506102dStholo Arguments to the commands. 2998506102dStholo 3008506102dStholo There is unfortunately some confusion between `cvs_options' and 3018506102dStholo`command_options'. `-l', when given as a `cvs_option', only affects 3028506102dStholosome of the commands. When it is given as a `command_option' is has a 3038506102dStholodifferent meaning, and is accepted by more commands. In other words, 3048506102dStholodo not take the above categorization too seriously. Look at the 3058506102dStholodocumentation instead. 3068506102dStholo 3078506102dStholo 3088506102dStholoFile: cvs.info, Node: Exit status, Next: ~/.cvsrc, Prev: Structure, Up: CVS commands 3098506102dStholo 3108506102dStholoCVS's exit status 3118506102dStholo================= 3128506102dStholo 3138506102dStholo CVS can indicate to the calling environment whether it succeeded or 3148506102dStholofailed by setting its "exit status". The exact way of testing the exit 3158506102dStholostatus will vary from one operating system to another. For example in 3168506102dStholoa unix shell script the `$?' variable will be 0 if the last command 3178506102dStholoreturned a successful exit status, or greater than 0 if the exit status 3188506102dStholoindicated failure. 3198506102dStholo 3208506102dStholo If CVS is successful, it returns a successful status; if there is an 3218506102dStholoerror, it prints an error message and returns a failure status. The 3228506102dStholoone exception to this is the `cvs diff' command. It will return a 3238506102dStholosuccessful status if it found no differences, or a failure status if 3248506102dStholothere were differences or if there was an error. Because this behavior 3258506102dStholoprovides no good way to detect errors, in the future it is possible that 3268506102dStholo`cvs diff' will be changed to behave like the other CVS commands. 3278506102dStholo 3288506102dStholo 3298506102dStholoFile: cvs.info, Node: ~/.cvsrc, Next: Global options, Prev: Exit status, Up: CVS commands 3308506102dStholo 3318506102dStholoDefault options and the ~/.cvsrc file 3328506102dStholo===================================== 3338506102dStholo 3348506102dStholo There are some `command_options' that are used so often that you 3358506102dStholomight have set up an alias or some other means to make sure you always 3368506102dStholospecify that option. One example (the one that drove the 3378506102dStholoimplementation of the `.cvsrc' support, actually) is that many people 3388506102dStholofind the default output of the `diff' command to be very hard to read, 3398506102dStholoand that either context diffs or unidiffs are much easier to understand. 3408506102dStholo 3418506102dStholo The `~/.cvsrc' file is a way that you can add default options to 3428506102dStholo`cvs_commands' within cvs, instead of relying on aliases or other shell 3438506102dStholoscripts. 3448506102dStholo 3458506102dStholo The format of the `~/.cvsrc' file is simple. The file is searched 3468506102dStholofor a line that begins with the same name as the `cvs_command' being 3478506102dStholoexecuted. If a match is found, then the remainder of the line is split 3488506102dStholoup (at whitespace characters) into separate options and added to the 3492f9d2fd9Stholocommand arguments _before_ any options from the command line. 3508506102dStholo 3518506102dStholo If a command has two names (e.g., `checkout' and `co'), the official 3528506102dStholoname, not necessarily the one used on the command line, will be used to 3538506102dStholomatch against the file. So if this is the contents of the user's 3548506102dStholo`~/.cvsrc' file: 3558506102dStholo 3568506102dStholo log -N 3578506102dStholo diff -u 3588506102dStholo update -P 3598506102dStholo checkout -P 3608506102dStholo 3618506102dStholothe command `cvs checkout foo' would have the `-P' option added to the 3628506102dStholoarguments, as well as `cvs co foo'. 3638506102dStholo 3648506102dStholo With the example file above, the output from `cvs diff foobar' will 3658506102dStholobe in unidiff format. `cvs diff -c foobar' will provide context diffs, 3668506102dStholoas usual. Getting "old" format diffs would be slightly more 3678506102dStholocomplicated, because `diff' doesn't have an option to specify use of 3688506102dStholothe "old" format, so you would need `cvs -f diff foobar'. 3698506102dStholo 3708506102dStholo In place of the command name you can use `cvs' to specify global 371e77048c1Stholooptions (*note Global options::). For example the following line in 3728506102dStholo`.cvsrc' 3738506102dStholo 3748506102dStholo cvs -z6 3758506102dStholo 3768506102dStholo causes CVS to use compression level 6. 3778506102dStholo 3788506102dStholo 3792f91a5f5StholoFile: cvs.info, Node: Global options, Next: Common options, Prev: ~/.cvsrc, Up: CVS commands 3802f91a5f5Stholo 3812f91a5f5StholoGlobal options 3822f91a5f5Stholo============== 3832f91a5f5Stholo 3842f91a5f5Stholo The available `cvs_options' (that are given to the left of 3852f91a5f5Stholo`cvs_command') are: 3862f91a5f5Stholo 3872f91a5f5Stholo`--allow-root=ROOTDIR' 3882f91a5f5Stholo Specify legal CVSROOT directory. See *Note Password 3892f91a5f5Stholo authentication server::. 3902f91a5f5Stholo 3912f91a5f5Stholo`-a' 3922f91a5f5Stholo Authenticate all communication between the client and the server. 3932f91a5f5Stholo Only has an effect on the CVS client. As of this writing, this is 3942f91a5f5Stholo only implemented when using a GSSAPI connection (*note GSSAPI 395e77048c1Stholo authenticated::). Authentication prevents certain sorts of attacks 396e77048c1Stholo involving hijacking the active TCP connection. Enabling 3972f91a5f5Stholo authentication does not enable encryption. 3982f91a5f5Stholo 3992f91a5f5Stholo`-b BINDIR' 4002f91a5f5Stholo In CVS 1.9.18 and older, this specified that RCS programs are in 4012f91a5f5Stholo the BINDIR directory. Current versions of CVS do not run RCS 4022f91a5f5Stholo programs; for compatibility this option is accepted, but it does 4032f91a5f5Stholo nothing. 4042f91a5f5Stholo 4052f91a5f5Stholo`-T TEMPDIR' 4062f91a5f5Stholo Use TEMPDIR as the directory where temporary files are located. 4072f91a5f5Stholo Overrides the setting of the `$TMPDIR' environment variable and 4082f91a5f5Stholo any precompiled directory. This parameter should be specified as 4092f91a5f5Stholo an absolute pathname. 4102f91a5f5Stholo 4112f91a5f5Stholo`-d CVS_ROOT_DIRECTORY' 4122f91a5f5Stholo Use CVS_ROOT_DIRECTORY as the root directory pathname of the 4132f91a5f5Stholo repository. Overrides the setting of the `$CVSROOT' environment 4142f91a5f5Stholo variable. *Note Repository::. 4152f91a5f5Stholo 4162f91a5f5Stholo`-e EDITOR' 4172f91a5f5Stholo Use EDITOR to enter revision log information. Overrides the 4182f91a5f5Stholo setting of the `$CVSEDITOR' and `$EDITOR' environment variables. 4192f91a5f5Stholo For more information, see *Note Committing your changes::. 4202f91a5f5Stholo 4212f91a5f5Stholo`-f' 4222f91a5f5Stholo Do not read the `~/.cvsrc' file. This option is most often used 4232f91a5f5Stholo because of the non-orthogonality of the CVS option set. For 4242f91a5f5Stholo example, the `cvs log' option `-N' (turn off display of tag names) 4252f91a5f5Stholo does not have a corresponding option to turn the display on. So 4262f91a5f5Stholo if you have `-N' in the `~/.cvsrc' entry for `log', you may need 4272f91a5f5Stholo to use `-f' to show the tag names. 4282f91a5f5Stholo 4292f91a5f5Stholo`-H' 4302f91a5f5Stholo`--help' 4312f91a5f5Stholo Display usage information about the specified `cvs_command' (but 4322f91a5f5Stholo do not actually execute the command). If you don't specify a 4332f91a5f5Stholo command name, `cvs -H' displays overall help for CVS, including a 4342f91a5f5Stholo list of other help options. 4352f91a5f5Stholo 4362f91a5f5Stholo`-l' 4372f91a5f5Stholo Do not log the `cvs_command' in the command history (but execute it 4382f91a5f5Stholo anyway). *Note history::, for information on command history. 4392f91a5f5Stholo 4402f91a5f5Stholo`-n' 4412f91a5f5Stholo Do not change any files. Attempt to execute the `cvs_command', 4422f91a5f5Stholo but only to issue reports; do not remove, update, or merge any 4432f91a5f5Stholo existing files, or create any new files. 4442f91a5f5Stholo 4452f91a5f5Stholo Note that CVS will not necessarily produce exactly the same output 4462f91a5f5Stholo as without `-n'. In some cases the output will be the same, but 4472f91a5f5Stholo in other cases CVS will skip some of the processing that would 4482f91a5f5Stholo have been required to produce the exact same output. 4492f91a5f5Stholo 4502f91a5f5Stholo`-Q' 4512f91a5f5Stholo Cause the command to be really quiet; the command will only 4522f91a5f5Stholo generate output for serious problems. 4532f91a5f5Stholo 4542f91a5f5Stholo`-q' 4552f91a5f5Stholo Cause the command to be somewhat quiet; informational messages, 4562f91a5f5Stholo such as reports of recursion through subdirectories, are 4572f91a5f5Stholo suppressed. 4582f91a5f5Stholo 4592f91a5f5Stholo`-r' 4606407bc5bStholo Make new working files read-only. Same effect as if the 4612f91a5f5Stholo `$CVSREAD' environment variable is set (*note Environment 462e77048c1Stholo variables::). The default is to make working files writable, 463e77048c1Stholo unless watches are on (*note Watches::). 4642f91a5f5Stholo 4652f91a5f5Stholo`-s VARIABLE=VALUE' 466e77048c1Stholo Set a user variable (*note Variables::). 4672f91a5f5Stholo 4682f91a5f5Stholo`-t' 4692f91a5f5Stholo Trace program execution; display messages showing the steps of CVS 4702f91a5f5Stholo activity. Particularly useful with `-n' to explore the potential 4712f91a5f5Stholo impact of an unfamiliar command. 4722f91a5f5Stholo 4732f91a5f5Stholo`-v' 4742f9d2fd9Stholo 4752f91a5f5Stholo`--version' 4762f91a5f5Stholo Display version and copyright information for CVS. 4772f91a5f5Stholo 4782f91a5f5Stholo`-w' 4792f91a5f5Stholo Make new working files read-write. Overrides the setting of the 4802f91a5f5Stholo `$CVSREAD' environment variable. Files are created read-write by 4812f91a5f5Stholo default, unless `$CVSREAD' is set or `-r' is given. 4822f91a5f5Stholo 4832f91a5f5Stholo`-x' 4842f91a5f5Stholo Encrypt all communication between the client and the server. Only 4852f91a5f5Stholo has an effect on the CVS client. As of this writing, this is only 4862f91a5f5Stholo implemented when using a GSSAPI connection (*note GSSAPI 487e77048c1Stholo authenticated::) or a Kerberos connection (*note Kerberos 488e77048c1Stholo authenticated::). Enabling encryption implies that message 4892f91a5f5Stholo traffic is also authenticated. Encryption support is not 4902f91a5f5Stholo available by default; it must be enabled using a special configure 4912f91a5f5Stholo option, `--enable-encryption', when you build CVS. 4922f91a5f5Stholo 4932f91a5f5Stholo`-z GZIP-LEVEL' 494e77048c1Stholo Set the compression level. Valid levels are 1 (high speed, low 495e77048c1Stholo compression) to 9 (low speed, high compression), or 0 to disable 496e77048c1Stholo compression (the default). Only has an effect on the CVS client. 4972f91a5f5Stholo 4982f91a5f5Stholo 499f79d7d1bStholoFile: cvs.info, Node: Common options, Next: admin, Prev: Global options, Up: CVS commands 500565bb110Stholo 501f79d7d1bStholoCommon command options 502f79d7d1bStholo====================== 503565bb110Stholo 504f79d7d1bStholo This section describes the `command_options' that are available 505f79d7d1bStholoacross several CVS commands. These options are always given to the 506f79d7d1bStholoright of `cvs_command'. Not all commands support all of these options; 507f79d7d1bStholoeach option is only supported for commands where it makes sense. 508f79d7d1bStholoHowever, when a command has one of these options you can almost always 509f79d7d1bStholocount on the same behavior of the option as in other commands. (Other 510f79d7d1bStholocommand options, which are listed with the individual commands, may have 511f79d7d1bStholodifferent behavior from one CVS command to the other). 512565bb110Stholo 513f79d7d1bStholo *Warning:* the `history' command is an exception; it supports many 514f79d7d1bStholooptions that conflict even with these standard options. 515565bb110Stholo 516f79d7d1bStholo`-D DATE_SPEC' 517f79d7d1bStholo Use the most recent revision no later than DATE_SPEC. DATE_SPEC 518f79d7d1bStholo is a single argument, a date description specifying a date in the 519f79d7d1bStholo past. 520565bb110Stholo 521f79d7d1bStholo The specification is "sticky" when you use it to make a private 522f79d7d1bStholo copy of a source file; that is, when you get a working file using 523f79d7d1bStholo `-D', CVS records the date you specified, so that further updates 524f79d7d1bStholo in the same directory will use the same date (for more information 525e77048c1Stholo on sticky tags/dates, *note Sticky tags::). 526565bb110Stholo 527f79d7d1bStholo `-D' is available with the `checkout', `diff', `export', `history', 528f79d7d1bStholo `rdiff', `rtag', and `update' commands. (The `history' command 529f79d7d1bStholo uses this option in a slightly different way; *note history 530e77048c1Stholo options::). 531565bb110Stholo 532f79d7d1bStholo A wide variety of date formats are supported by CVS. The most 533f79d7d1bStholo standard ones are ISO8601 (from the International Standards 534f79d7d1bStholo Organization) and the Internet e-mail standard (specified in 535f79d7d1bStholo RFC822 as amended by RFC1123). 536565bb110Stholo 537f79d7d1bStholo ISO8601 dates have many variants but a few examples are: 538565bb110Stholo 539f79d7d1bStholo 1972-09-24 540f79d7d1bStholo 1972-09-24 20:05 541565bb110Stholo 5428506102dStholo There are a lot more ISO8601 date formats, and CVS accepts many of 5432f9d2fd9Stholo them, but you probably don't want to hear the _whole_ long story 5448506102dStholo :-). 545f79d7d1bStholo 546f79d7d1bStholo In addition to the dates allowed in Internet e-mail itself, CVS 547f79d7d1bStholo also allows some of the fields to be omitted. For example: 548f79d7d1bStholo 549f79d7d1bStholo 24 Sep 1972 20:05 550f79d7d1bStholo 24 Sep 551f79d7d1bStholo 552f79d7d1bStholo The date is interpreted as being in the local timezone, unless a 553f79d7d1bStholo specific timezone is specified. 554f79d7d1bStholo 555f79d7d1bStholo These two date formats are preferred. However, CVS currently 556f79d7d1bStholo accepts a wide variety of other date formats. They are 557f79d7d1bStholo intentionally not documented here in any detail, and future 558f79d7d1bStholo versions of CVS might not accept all of them. 559f79d7d1bStholo 560f79d7d1bStholo One such format is `MONTH/DAY/YEAR'. This may confuse people who 561f79d7d1bStholo are accustomed to having the month and day in the other order; 562f79d7d1bStholo `1/4/96' is January 4, not April 1. 563f79d7d1bStholo 564f79d7d1bStholo Remember to quote the argument to the `-D' flag so that your shell 565f79d7d1bStholo doesn't interpret spaces as argument separators. A command using 566f79d7d1bStholo the `-D' flag can look like this: 567f79d7d1bStholo 568f79d7d1bStholo $ cvs diff -D "1 hour ago" cvs.texinfo 569f79d7d1bStholo 570f79d7d1bStholo`-f' 571f79d7d1bStholo When you specify a particular date or tag to CVS commands, they 572f79d7d1bStholo normally ignore files that do not contain the tag (or did not 573f79d7d1bStholo exist prior to the date) that you specified. Use the `-f' option 574f79d7d1bStholo if you want files retrieved even when there is no match for the 575f79d7d1bStholo tag or date. (The most recent revision of the file will be used). 576f79d7d1bStholo 5772f9d2fd9Stholo Note that even with `-f', a tag that you specify must exist (that 5782f9d2fd9Stholo is, in some file, not necessary in every file). This is so that 5792f9d2fd9Stholo CVS will continue to give an error if you mistype a tag name. 5802f9d2fd9Stholo 581f79d7d1bStholo `-f' is available with these commands: `annotate', `checkout', 582f79d7d1bStholo `export', `rdiff', `rtag', and `update'. 583f79d7d1bStholo 584f79d7d1bStholo *Warning:* The `commit' and `remove' commands also have a `-f' 585f79d7d1bStholo option, but it has a different behavior for those commands. See 586f79d7d1bStholo *Note commit options::, and *Note Removing files::. 587f79d7d1bStholo 588f79d7d1bStholo`-k KFLAG' 589f79d7d1bStholo Alter the default processing of keywords. *Note Keyword 590f79d7d1bStholo substitution::, for the meaning of KFLAG. Your KFLAG 591f79d7d1bStholo specification is "sticky" when you use it to create a private copy 592f79d7d1bStholo of a source file; that is, when you use this option with the 593f79d7d1bStholo `checkout' or `update' commands, CVS associates your selected 594f79d7d1bStholo KFLAG with the file, and continues to use it with future update 595f79d7d1bStholo commands on the same file until you specify otherwise. 596f79d7d1bStholo 597f79d7d1bStholo The `-k' option is available with the `add', `checkout', `diff', 598f79d7d1bStholo `import' and `update' commands. 599f79d7d1bStholo 600f79d7d1bStholo`-l' 601f79d7d1bStholo Local; run only in current working directory, rather than 602f79d7d1bStholo recursing through subdirectories. 603f79d7d1bStholo 604f79d7d1bStholo *Warning:* this is not the same as the overall `cvs -l' option, 605f79d7d1bStholo which you can specify to the left of a cvs command! 606f79d7d1bStholo 607f79d7d1bStholo Available with the following commands: `annotate', `checkout', 608f79d7d1bStholo `commit', `diff', `edit', `editors', `export', `log', `rdiff', 609f79d7d1bStholo `remove', `rtag', `status', `tag', `unedit', `update', `watch', 610f79d7d1bStholo and `watchers'. 611f79d7d1bStholo 612f79d7d1bStholo`-m MESSAGE' 613f79d7d1bStholo Use MESSAGE as log information, instead of invoking an editor. 614f79d7d1bStholo 615f79d7d1bStholo Available with the following commands: `add', `commit' and 616f79d7d1bStholo `import'. 617f79d7d1bStholo 618f79d7d1bStholo`-n' 619f79d7d1bStholo Do not run any checkout/commit/tag program. (A program can be 620f79d7d1bStholo specified to run on each of these activities, in the modules 621e77048c1Stholo database (*note modules::); this option bypasses it). 622f79d7d1bStholo 623f79d7d1bStholo *Warning:* this is not the same as the overall `cvs -n' option, 624f79d7d1bStholo which you can specify to the left of a cvs command! 625f79d7d1bStholo 626f79d7d1bStholo Available with the `checkout', `commit', `export', and `rtag' 627f79d7d1bStholo commands. 628f79d7d1bStholo 629f79d7d1bStholo`-P' 630f79d7d1bStholo Prune empty directories. See *Note Removing directories::. 631f79d7d1bStholo 632f79d7d1bStholo`-p' 633f79d7d1bStholo Pipe the files retrieved from the repository to standard output, 634f79d7d1bStholo rather than writing them in the current directory. Available with 635f79d7d1bStholo the `checkout' and `update' commands. 636f79d7d1bStholo 637f79d7d1bStholo`-R' 638f79d7d1bStholo Process directories recursively. This is on by default. 639f79d7d1bStholo 640f79d7d1bStholo Available with the following commands: `annotate', `checkout', 641f79d7d1bStholo `commit', `diff', `edit', `editors', `export', `rdiff', `remove', 642f79d7d1bStholo `rtag', `status', `tag', `unedit', `update', `watch', and 643f79d7d1bStholo `watchers'. 644f79d7d1bStholo 645f79d7d1bStholo`-r TAG' 646f79d7d1bStholo Use the revision specified by the TAG argument instead of the 647f79d7d1bStholo default "head" revision. As well as arbitrary tags defined with 648f79d7d1bStholo the `tag' or `rtag' command, two special tags are always 649f79d7d1bStholo available: `HEAD' refers to the most recent version available in 650f79d7d1bStholo the repository, and `BASE' refers to the revision you last checked 651f79d7d1bStholo out into the current working directory. 652f79d7d1bStholo 653f79d7d1bStholo The tag specification is sticky when you use this with `checkout' 654f79d7d1bStholo or `update' to make your own copy of a file: CVS remembers the tag 655f79d7d1bStholo and continues to use it on future update commands, until you 656f79d7d1bStholo specify otherwise (for more information on sticky tags/dates, 657e77048c1Stholo *note Sticky tags::). 6582f9d2fd9Stholo 6592f9d2fd9Stholo The tag can be either a symbolic or numeric tag, as described in 6602f9d2fd9Stholo *Note Tags::, or the name of a branch, as described in *Note 6612f9d2fd9Stholo Branching and merging::. 662f79d7d1bStholo 663f79d7d1bStholo Specifying the `-q' global option along with the `-r' command 664f79d7d1bStholo option is often useful, to suppress the warning messages when the 665f79d7d1bStholo RCS file does not contain the specified tag. 666f79d7d1bStholo 667f79d7d1bStholo *Warning:* this is not the same as the overall `cvs -r' option, 668f79d7d1bStholo which you can specify to the left of a CVS command! 669f79d7d1bStholo 670f79d7d1bStholo `-r' is available with the `checkout', `commit', `diff', 671f79d7d1bStholo `history', `export', `rdiff', `rtag', and `update' commands. 672f79d7d1bStholo 673f79d7d1bStholo`-W' 674f79d7d1bStholo Specify file names that should be filtered. You can use this 675f79d7d1bStholo option repeatedly. The spec can be a file name pattern of the 676f79d7d1bStholo same type that you can specify in the `.cvswrappers' file. 677f79d7d1bStholo Available with the following commands: `import', and `update'. 678f79d7d1bStholo 679f79d7d1bStholo 680f79d7d1bStholoFile: cvs.info, Node: admin, Next: checkout, Prev: Common options, Up: CVS commands 681f79d7d1bStholo 682f79d7d1bStholoadmin--Administration 683f79d7d1bStholo===================== 684f79d7d1bStholo 685f79d7d1bStholo * Requires: repository, working directory. 686f79d7d1bStholo 687f79d7d1bStholo * Changes: repository. 688f79d7d1bStholo 689f79d7d1bStholo * Synonym: rcs 690f79d7d1bStholo 691f79d7d1bStholo This is the CVS interface to assorted administrative facilities. 692f79d7d1bStholoSome of them have questionable usefulness for CVS but exist for 693f79d7d1bStholohistorical purposes. Some of the questionable options are likely to 6942f9d2fd9Stholodisappear in the future. This command _does_ work recursively, so 695f79d7d1bStholoextreme care should be used. 696f79d7d1bStholo 697f79d7d1bStholo On unix, if there is a group named `cvsadmin', only members of that 6982f9d2fd9Sthologroup can run `cvs admin' (except for the `cvs admin -k' command, which 6992f9d2fd9Stholocan be run by anybody). This group should exist on the server, or any 7002f9d2fd9Stholosystem running the non-client/server CVS. To disallow `cvs admin' for 7012f9d2fd9Stholoall users, create a group with no users in it. On NT, the `cvsadmin' 7022f9d2fd9Stholofeature does not exist and all users can run `cvs admin'. 703f79d7d1bStholo 704f79d7d1bStholo* Menu: 705f79d7d1bStholo 706f79d7d1bStholo* admin options:: admin options 707f79d7d1bStholo 708f79d7d1bStholo 709f79d7d1bStholoFile: cvs.info, Node: admin options, Up: admin 710f79d7d1bStholo 711f79d7d1bStholoadmin options 712f79d7d1bStholo------------- 713f79d7d1bStholo 714f79d7d1bStholo Some of these options have questionable usefulness for CVS but exist 715f79d7d1bStholofor historical purposes. Some even make it impossible to use CVS until 716f79d7d1bStholoyou undo the effect! 717f79d7d1bStholo 718f79d7d1bStholo`-AOLDFILE' 719f79d7d1bStholo Might not work together with CVS. Append the access list of 720f79d7d1bStholo OLDFILE to the access list of the RCS file. 721f79d7d1bStholo 722f79d7d1bStholo`-aLOGINS' 723f79d7d1bStholo Might not work together with CVS. Append the login names 724f79d7d1bStholo appearing in the comma-separated list LOGINS to the access list of 725f79d7d1bStholo the RCS file. 726f79d7d1bStholo 727f79d7d1bStholo`-b[REV]' 728f79d7d1bStholo Set the default branch to REV. In CVS, you normally do not 729e77048c1Stholo manipulate default branches; sticky tags (*note Sticky tags::) are 730e77048c1Stholo a better way to decide which branch you want to work on. There is 731e77048c1Stholo one reason to run `cvs admin -b': to revert to the vendor's 732e77048c1Stholo version when using vendor branches (*note Reverting local 733e77048c1Stholo changes::). There can be no space between `-b' and its argument. 734f79d7d1bStholo 735f79d7d1bStholo`-cSTRING' 736f79d7d1bStholo Sets the comment leader to STRING. The comment leader is not used 737f79d7d1bStholo by current versions of CVS or RCS 5.7. Therefore, you can almost 738f79d7d1bStholo surely not worry about it. *Note Keyword substitution::. 739f79d7d1bStholo 740f79d7d1bStholo`-e[LOGINS]' 741f79d7d1bStholo Might not work together with CVS. Erase the login names appearing 742f79d7d1bStholo in the comma-separated list LOGINS from the access list of the RCS 7432f9d2fd9Stholo file. If LOGINS is omitted, erase the entire access list. There 7442f9d2fd9Stholo can be no space between `-e' and its argument. 745f79d7d1bStholo 746f79d7d1bStholo`-I' 747f79d7d1bStholo Run interactively, even if the standard input is not a terminal. 748f79d7d1bStholo This option does not work with the client/server CVS and is likely 749f79d7d1bStholo to disappear in a future release of CVS. 750f79d7d1bStholo 751f79d7d1bStholo`-i' 752f79d7d1bStholo Useless with CVS. This creates and initializes a new RCS file, 753f79d7d1bStholo without depositing a revision. With CVS, add files with the `cvs 754e77048c1Stholo add' command (*note Adding files::). 755f79d7d1bStholo 756f79d7d1bStholo`-kSUBST' 757f79d7d1bStholo Set the default keyword substitution to SUBST. *Note Keyword 758f79d7d1bStholo substitution::. Giving an explicit `-k' option to `cvs update', 759f79d7d1bStholo `cvs export', or `cvs checkout' overrides this default. 760f79d7d1bStholo 761f79d7d1bStholo`-l[REV]' 762f79d7d1bStholo Lock the revision with number REV. If a branch is given, lock the 763f79d7d1bStholo latest revision on that branch. If REV is omitted, lock the 764f79d7d1bStholo latest revision on the default branch. There can be no space 765f79d7d1bStholo between `-l' and its argument. 766f79d7d1bStholo 767f79d7d1bStholo This can be used in conjunction with the `rcslock.pl' script in 768f79d7d1bStholo the `contrib' directory of the CVS source distribution to provide 769f79d7d1bStholo reserved checkouts (where only one user can be editing a given 770f79d7d1bStholo file at a time). See the comments in that file for details (and 771f79d7d1bStholo see the `README' file in that directory for disclaimers about the 772f79d7d1bStholo unsupported nature of contrib). According to comments in that 773f79d7d1bStholo file, locking must set to strict (which is the default). 774f79d7d1bStholo 775f79d7d1bStholo`-L' 776f79d7d1bStholo Set locking to strict. Strict locking means that the owner of an 777f79d7d1bStholo RCS file is not exempt from locking for checkin. For use with 778f79d7d1bStholo CVS, strict locking must be set; see the discussion under the `-l' 779f79d7d1bStholo option above. 780f79d7d1bStholo 781f79d7d1bStholo`-mREV:MSG' 782f79d7d1bStholo Replace the log message of revision REV with MSG. 783f79d7d1bStholo 784f79d7d1bStholo`-NNAME[:[REV]]' 785f79d7d1bStholo Act like `-n', except override any previous assignment of NAME. 786f79d7d1bStholo For use with magic branches, see *Note Magic branch numbers::. 787f79d7d1bStholo 788f79d7d1bStholo`-nNAME[:[REV]]' 789f79d7d1bStholo Associate the symbolic name NAME with the branch or revision REV. 790f79d7d1bStholo It is normally better to use `cvs tag' or `cvs rtag' instead. 791f79d7d1bStholo Delete the symbolic name if both `:' and REV are omitted; 792f79d7d1bStholo otherwise, print an error message if NAME is already associated 793f79d7d1bStholo with another number. If REV is symbolic, it is expanded before 794f79d7d1bStholo association. A REV consisting of a branch number followed by a 795f79d7d1bStholo `.' stands for the current latest revision in the branch. A `:' 796f79d7d1bStholo with an empty REV stands for the current latest revision on the 797f79d7d1bStholo default branch, normally the trunk. For example, `cvs admin 798f79d7d1bStholo -nNAME:' associates NAME with the current latest revision of all 799f79d7d1bStholo the RCS files; this contrasts with `cvs admin -nNAME:$' which 800f79d7d1bStholo associates NAME with the revision numbers extracted from keyword 801f79d7d1bStholo strings in the corresponding working files. 802f79d7d1bStholo 803f79d7d1bStholo`-oRANGE' 804f79d7d1bStholo Deletes ("outdates") the revisions given by RANGE. 805f79d7d1bStholo 806f79d7d1bStholo Note that this command can be quite dangerous unless you know 8072f9d2fd9Stholo _exactly_ what you are doing (for example see the warnings below 808f79d7d1bStholo about how the REV1:REV2 syntax is confusing). 809f79d7d1bStholo 810f79d7d1bStholo If you are short on disc this option might help you. But think 811f79d7d1bStholo twice before using it--there is no way short of restoring the 812f79d7d1bStholo latest backup to undo this command! If you delete different 813f79d7d1bStholo revisions than you planned, either due to carelessness or (heaven 814f79d7d1bStholo forbid) a CVS bug, there is no opportunity to correct the error 815f79d7d1bStholo before the revisions are deleted. It probably would be a good 816f79d7d1bStholo idea to experiment on a copy of the repository first. 817f79d7d1bStholo 818f79d7d1bStholo Specify RANGE in one of the following ways: 819f79d7d1bStholo 820f79d7d1bStholo `REV1::REV2' 821f79d7d1bStholo Collapse all revisions between rev1 and rev2, so that CVS 822f79d7d1bStholo only stores the differences associated with going from rev1 823f79d7d1bStholo to rev2, not intermediate steps. For example, after `-o 824f79d7d1bStholo 1.3::1.5' one can retrieve revision 1.3, revision 1.5, or the 825f79d7d1bStholo differences to get from 1.3 to 1.5, but not the revision 1.4, 826f79d7d1bStholo or the differences between 1.3 and 1.4. Other examples: `-o 827f79d7d1bStholo 1.3::1.4' and `-o 1.3::1.3' have no effect, because there are 828f79d7d1bStholo no intermediate revisions to remove. 829f79d7d1bStholo 830f79d7d1bStholo `::REV' 831f79d7d1bStholo Collapse revisions between the beginning of the branch 832f79d7d1bStholo containing REV and REV itself. The branchpoint and REV are 833f79d7d1bStholo left intact. For example, `-o ::1.3.2.6' deletes revision 834f79d7d1bStholo 1.3.2.1, revision 1.3.2.5, and everything in between, but 835f79d7d1bStholo leaves 1.3 and 1.3.2.6 intact. 836f79d7d1bStholo 837f79d7d1bStholo `REV::' 838f79d7d1bStholo Collapse revisions between REV and the end of the branch 839f79d7d1bStholo containing REV. Revision REV is left intact but the head 840f79d7d1bStholo revision is deleted. 841f79d7d1bStholo 842f79d7d1bStholo `REV' 843f79d7d1bStholo Delete the revision REV. For example, `-o 1.3' is equivalent 844f79d7d1bStholo to `-o 1.2::1.4'. 845f79d7d1bStholo 846f79d7d1bStholo `REV1:REV2' 847f79d7d1bStholo Delete the revisions from REV1 to REV2, inclusive, on the 848f79d7d1bStholo same branch. One will not be able to retrieve REV1 or REV2 849f79d7d1bStholo or any of the revisions in between. For example, the command 850f79d7d1bStholo `cvs admin -oR_1_01:R_1_02 .' is rarely useful. It means to 851f79d7d1bStholo delete revisions up to, and including, the tag R_1_02. But 852f79d7d1bStholo beware! If there are files that have not changed between 8532f9d2fd9Stholo R_1_02 and R_1_03 the file will have _the same_ numerical 854f79d7d1bStholo revision number assigned to the tags R_1_02 and R_1_03. So 855f79d7d1bStholo not only will it be impossible to retrieve R_1_02; R_1_03 856f79d7d1bStholo will also have to be restored from the tapes! In most cases 857f79d7d1bStholo you want to specify REV1::REV2 instead. 858f79d7d1bStholo 859f79d7d1bStholo `:REV' 860f79d7d1bStholo Delete revisions from the beginning of the branch containing 861f79d7d1bStholo REV up to and including REV. 862f79d7d1bStholo 863f79d7d1bStholo `REV:' 864f79d7d1bStholo Delete revisions from revision REV, including REV itself, to 865f79d7d1bStholo the end of the branch containing REV. 866f79d7d1bStholo 867f79d7d1bStholo None of the revisions to be deleted may have branches or locks. 868f79d7d1bStholo 869f79d7d1bStholo If any of the revisions to be deleted have symbolic names, and one 870f79d7d1bStholo specifies one of the `::' syntaxes, then CVS will give an error 871f79d7d1bStholo and not delete any revisions. If you really want to delete both 872f79d7d1bStholo the symbolic names and the revisions, first delete the symbolic 873f79d7d1bStholo names with `cvs tag -d', then run `cvs admin -o'. If one 874f79d7d1bStholo specifies the non-`::' syntaxes, then CVS will delete the 875f79d7d1bStholo revisions but leave the symbolic names pointing to nonexistent 876f79d7d1bStholo revisions. This behavior is preserved for compatibility with 877f79d7d1bStholo previous versions of CVS, but because it isn't very useful, in the 878f79d7d1bStholo future it may change to be like the `::' case. 879f79d7d1bStholo 880f79d7d1bStholo Due to the way CVS handles branches REV cannot be specified 881f79d7d1bStholo symbolically if it is a branch. *Note Magic branch numbers::, for 882f79d7d1bStholo an explanation. 883f79d7d1bStholo 884f79d7d1bStholo Make sure that no-one has checked out a copy of the revision you 885f79d7d1bStholo outdate. Strange things will happen if he starts to edit it and 886f79d7d1bStholo tries to check it back in. For this reason, this option is not a 887f79d7d1bStholo good way to take back a bogus commit; commit a new revision 888e77048c1Stholo undoing the bogus change instead (*note Merging two revisions::). 889f79d7d1bStholo 890f79d7d1bStholo`-q' 891f79d7d1bStholo Run quietly; do not print diagnostics. 892f79d7d1bStholo 893f79d7d1bStholo`-sSTATE[:REV]' 894f79d7d1bStholo Useful with CVS. Set the state attribute of the revision REV to 895f79d7d1bStholo STATE. If REV is a branch number, assume the latest revision on 896f79d7d1bStholo that branch. If REV is omitted, assume the latest revision on the 897f79d7d1bStholo default branch. Any identifier is acceptable for STATE. A useful 898f79d7d1bStholo set of states is `Exp' (for experimental), `Stab' (for stable), 899f79d7d1bStholo and `Rel' (for released). By default, the state of a new revision 900f79d7d1bStholo is set to `Exp' when it is created. The state is visible in the 901e77048c1Stholo output from CVS LOG (*note log::), and in the `$Log: cvs.info-5,v $ 902*55b57aafStholo output from CVS LOG (*note log::), and in the `Revision 1.3 2001/09/30 19:44:54 tholo 903*55b57aafStholo output from CVS LOG (*note log::), and in the `Revert to distributed version 904*55b57aafStholo output from CVS LOG (*note log::), and in the ` 905*55b57aafStholo output from CVS LOG (*note log::), and in the `Revision 1.1.1.18 2001/09/28 22:48:51 tholo 906*55b57aafStholo output from CVS LOG (*note log::), and in the `Latest from Cyclic Software 907e77048c1Stholo output from CVS LOG (*note log::), and in the `' and 908e77048c1Stholo `$State: Exp $' keywords (*note Keyword substitution::). Note that CVS 909f79d7d1bStholo uses the `dead' state for its own purposes; to take a file to or 910f79d7d1bStholo from the `dead' state use commands like `cvs remove' and `cvs 911f79d7d1bStholo add', not `cvs admin -s'. 912f79d7d1bStholo 913f79d7d1bStholo`-t[FILE]' 914f79d7d1bStholo Useful with CVS. Write descriptive text from the contents of the 915f79d7d1bStholo named FILE into the RCS file, deleting the existing text. The 916f79d7d1bStholo FILE pathname may not begin with `-'. The descriptive text can be 917e77048c1Stholo seen in the output from `cvs log' (*note log::). There can be no 918f79d7d1bStholo space between `-t' and its argument. 919f79d7d1bStholo 920f79d7d1bStholo If FILE is omitted, obtain the text from standard input, 921f79d7d1bStholo terminated by end-of-file or by a line containing `.' by itself. 922e77048c1Stholo Prompt for the text if interaction is possible; see `-I'. 923f79d7d1bStholo 924f79d7d1bStholo`-t-STRING' 925f79d7d1bStholo Similar to `-tFILE'. Write descriptive text from the STRING into 926f79d7d1bStholo the RCS file, deleting the existing text. There can be no space 927f79d7d1bStholo between `-t' and its argument. 928f79d7d1bStholo 929f79d7d1bStholo`-U' 930f79d7d1bStholo Set locking to non-strict. Non-strict locking means that the 931f79d7d1bStholo owner of a file need not lock a revision for checkin. For use 932f79d7d1bStholo with CVS, strict locking must be set; see the discussion under the 933f79d7d1bStholo `-l' option above. 934f79d7d1bStholo 935f79d7d1bStholo`-u[REV]' 936f79d7d1bStholo See the option `-l' above, for a discussion of using this option 937f79d7d1bStholo with CVS. Unlock the revision with number REV. If a branch is 938f79d7d1bStholo given, unlock the latest revision on that branch. If REV is 939f79d7d1bStholo omitted, remove the latest lock held by the caller. Normally, 94043c1707eStholo only the locker of a revision may unlock it; somebody else 94143c1707eStholo unlocking a revision breaks the lock. This causes the original 94243c1707eStholo locker to be sent a `commit' notification (*note Getting 94343c1707eStholo Notified::). There can be no space between `-u' and its argument. 944f79d7d1bStholo 945f79d7d1bStholo`-VN' 946f79d7d1bStholo In previous versions of CVS, this option meant to write an RCS 947f79d7d1bStholo file which would be acceptable to RCS version N, but it is now 948f79d7d1bStholo obsolete and specifying it will produce an error. 949f79d7d1bStholo 950f79d7d1bStholo`-xSUFFIXES' 951f79d7d1bStholo In previous versions of CVS, this was documented as a way of 952f79d7d1bStholo specifying the names of the RCS files. However, CVS has always 953f79d7d1bStholo required that the RCS files used by CVS end in `,v', so this 954f79d7d1bStholo option has never done anything useful. 955565bb110Stholo 956565bb110Stholo 957565bb110StholoFile: cvs.info, Node: checkout, Next: commit, Prev: admin, Up: CVS commands 958565bb110Stholo 959565bb110Stholocheckout--Check out sources for editing 960565bb110Stholo======================================= 961565bb110Stholo 962565bb110Stholo * Synopsis: checkout [options] modules... 963565bb110Stholo 964565bb110Stholo * Requires: repository. 965565bb110Stholo 966565bb110Stholo * Changes: working directory. 967565bb110Stholo 968565bb110Stholo * Synonyms: co, get 969565bb110Stholo 970f79d7d1bStholo Create or update a working directory containing copies of the source 971f79d7d1bStholofiles specified by MODULES. You must execute `checkout' before using 972f79d7d1bStholomost of the other CVS commands, since most of them operate on your 973f79d7d1bStholoworking directory. 974565bb110Stholo 975f79d7d1bStholo The MODULES are either symbolic names for some collection of source 976f79d7d1bStholodirectories and files, or paths to directories or files in the 977f79d7d1bStholorepository. The symbolic names are defined in the `modules' file. 978f79d7d1bStholo*Note modules::. 979565bb110Stholo 980565bb110Stholo Depending on the modules you specify, `checkout' may recursively 981565bb110Stholocreate directories and populate them with the appropriate source files. 982565bb110StholoYou can then edit these source files at any time (regardless of 983565bb110Stholowhether other software developers are editing their own copies of the 984565bb110Stholosources); update them to include new changes applied by others to the 985565bb110Stholosource repository; or commit your work as a permanent change to the 986565bb110Stholosource repository. 987565bb110Stholo 988565bb110Stholo Note that `checkout' is used to create directories. The top-level 989565bb110Stholodirectory created is always added to the directory where `checkout' is 990565bb110Stholoinvoked, and usually has the same name as the specified module. In the 991565bb110Stholocase of a module alias, the created sub-directory may have a different 992565bb110Stholoname, but you can be sure that it will be a sub-directory, and that 993565bb110Stholo`checkout' will show the relative path leading to each file as it is 994565bb110Stholoextracted into your private work area (unless you specify the `-Q' 995565bb110Sthologlobal option). 996565bb110Stholo 997565bb110Stholo The files created by `checkout' are created read-write, unless the 998e77048c1Stholo`-r' option to CVS (*note Global options::) is specified, the `CVSREAD' 999e77048c1Stholoenvironment variable is specified (*note Environment variables::), or a 1000e77048c1Stholowatch is in effect for that file (*note Watches::). 1001565bb110Stholo 1002f79d7d1bStholo Note that running `checkout' on a directory that was already built 1003f79d7d1bStholoby a prior `checkout' is also permitted. This is similar to specifying 1004f79d7d1bStholothe `-d' option to the `update' command in the sense that new 1005f79d7d1bStholodirectories that have been created in the repository will appear in 1006f79d7d1bStholoyour work area. However, `checkout' takes a module name whereas 1007f79d7d1bStholo`update' takes a directory name. Also to use `checkout' this way it 1008f79d7d1bStholomust be run from the top level directory (where you originally ran 1009f79d7d1bStholo`checkout' from), so before you run `checkout' to update an existing 1010f79d7d1bStholodirectory, don't forget to change your directory to the top level 1011f79d7d1bStholodirectory. 1012565bb110Stholo 1013565bb110Stholo For the output produced by the `checkout' command see *Note update 1014565bb110Stholooutput::. 1015565bb110Stholo 1016565bb110Stholo* Menu: 1017565bb110Stholo 1018565bb110Stholo* checkout options:: checkout options 1019565bb110Stholo* checkout examples:: checkout examples 1020565bb110Stholo 1021e77048c1Stholo 1022e77048c1StholoFile: cvs.info, Node: checkout options, Next: checkout examples, Up: checkout 1023e77048c1Stholo 1024e77048c1Stholocheckout options 1025e77048c1Stholo---------------- 1026e77048c1Stholo 1027e77048c1Stholo These standard options are supported by `checkout' (*note Common 1028e77048c1Stholooptions::, for a complete description of them): 1029e77048c1Stholo 1030e77048c1Stholo`-D DATE' 1031e77048c1Stholo Use the most recent revision no later than DATE. This option is 1032e77048c1Stholo sticky, and implies `-P'. See *Note Sticky tags::, for more 1033e77048c1Stholo information on sticky tags/dates. 1034e77048c1Stholo 1035e77048c1Stholo`-f' 1036e77048c1Stholo Only useful with the `-D DATE' or `-r TAG' flags. If no matching 1037e77048c1Stholo revision is found, retrieve the most recent revision (instead of 1038e77048c1Stholo ignoring the file). 1039e77048c1Stholo 1040e77048c1Stholo`-k KFLAG' 1041e77048c1Stholo Process keywords according to KFLAG. See *Note Keyword 1042e77048c1Stholo substitution::. This option is sticky; future updates of this 1043e77048c1Stholo file in this working directory will use the same KFLAG. The 1044e77048c1Stholo `status' command can be viewed to see the sticky options. See 1045e77048c1Stholo *Note Invoking CVS::, for more information on the `status' command. 1046e77048c1Stholo 1047e77048c1Stholo`-l' 1048e77048c1Stholo Local; run only in current working directory. 1049e77048c1Stholo 1050e77048c1Stholo`-n' 1051e77048c1Stholo Do not run any checkout program (as specified with the `-o' option 1052e77048c1Stholo in the modules file; *note modules::). 1053e77048c1Stholo 1054e77048c1Stholo`-P' 1055e77048c1Stholo Prune empty directories. See *Note Moving directories::. 1056e77048c1Stholo 1057e77048c1Stholo`-p' 1058e77048c1Stholo Pipe files to the standard output. 1059e77048c1Stholo 1060e77048c1Stholo`-R' 1061e77048c1Stholo Checkout directories recursively. This option is on by default. 1062e77048c1Stholo 1063e77048c1Stholo`-r TAG' 1064e77048c1Stholo Use revision TAG. This option is sticky, and implies `-P'. See 1065e77048c1Stholo *Note Sticky tags::, for more information on sticky tags/dates. 1066e77048c1Stholo 1067e77048c1Stholo In addition to those, you can use these special command options with 1068e77048c1Stholo`checkout': 1069e77048c1Stholo 1070e77048c1Stholo`-A' 1071e77048c1Stholo Reset any sticky tags, dates, or `-k' options. See *Note Sticky 1072e77048c1Stholo tags::, for more information on sticky tags/dates. 1073e77048c1Stholo 1074e77048c1Stholo`-c' 1075e77048c1Stholo Copy the module file, sorted, to the standard output, instead of 1076e77048c1Stholo creating or modifying any files or directories in your working 1077e77048c1Stholo directory. 1078e77048c1Stholo 1079e77048c1Stholo`-d DIR' 1080e77048c1Stholo Create a directory called DIR for the working files, instead of 1081e77048c1Stholo using the module name. In general, using this flag is equivalent 1082e77048c1Stholo to using `mkdir DIR; cd DIR' followed by the checkout command 1083e77048c1Stholo without the `-d' flag. 1084e77048c1Stholo 1085e77048c1Stholo There is an important exception, however. It is very convenient 1086e77048c1Stholo when checking out a single item to have the output appear in a 1087e77048c1Stholo directory that doesn't contain empty intermediate directories. In 1088e77048c1Stholo this case _only_, CVS tries to "shorten" pathnames to avoid those 1089e77048c1Stholo empty directories. 1090e77048c1Stholo 1091e77048c1Stholo For example, given a module `foo' that contains the file `bar.c', 1092e77048c1Stholo the command `cvs co -d dir foo' will create directory `dir' and 1093e77048c1Stholo place `bar.c' inside. Similarly, given a module `bar' which has 1094e77048c1Stholo subdirectory `baz' wherein there is a file `quux.c', the command 1095e77048c1Stholo `cvs -d dir co bar/baz' will create directory `dir' and place 1096e77048c1Stholo `quux.c' inside. 1097e77048c1Stholo 1098e77048c1Stholo Using the `-N' flag will defeat this behavior. Given the same 1099e77048c1Stholo module definitions above, `cvs co -N -d dir foo' will create 1100e77048c1Stholo directories `dir/foo' and place `bar.c' inside, while `cvs co -N -d 1101e77048c1Stholo dir bar/baz' will create directories `dir/bar/baz' and place 1102e77048c1Stholo `quux.c' inside. 1103e77048c1Stholo 1104e77048c1Stholo`-j TAG' 1105e77048c1Stholo With two `-j' options, merge changes from the revision specified 1106e77048c1Stholo with the first `-j' option to the revision specified with the 1107e77048c1Stholo second `j' option, into the working directory. 1108e77048c1Stholo 1109e77048c1Stholo With one `-j' option, merge changes from the ancestor revision to 1110e77048c1Stholo the revision specified with the `-j' option, into the working 1111e77048c1Stholo directory. The ancestor revision is the common ancestor of the 1112e77048c1Stholo revision which the working directory is based on, and the revision 1113e77048c1Stholo specified in the `-j' option. 1114e77048c1Stholo 1115e77048c1Stholo In addition, each -j option can contain an optional date 1116e77048c1Stholo specification which, when used with branches, can limit the chosen 1117e77048c1Stholo revision to one within a specific date. An optional date is 1118e77048c1Stholo specified by adding a colon (:) to the tag: 1119e77048c1Stholo `-jSYMBOLIC_TAG:DATE_SPECIFIER'. 1120e77048c1Stholo 1121e77048c1Stholo *Note Branching and merging::. 1122e77048c1Stholo 1123e77048c1Stholo`-N' 1124e77048c1Stholo Only useful together with `-d DIR'. With this option, CVS will 1125e77048c1Stholo not "shorten" module paths in your working directory when you 1126e77048c1Stholo check out a single module. See the `-d' flag for examples and a 1127e77048c1Stholo discussion. 1128e77048c1Stholo 1129e77048c1Stholo`-s' 1130e77048c1Stholo Like `-c', but include the status of all modules, and sort it by 1131e77048c1Stholo the status string. *Note modules::, for info about the `-s' 1132e77048c1Stholo option that is used inside the modules file to set the module 1133e77048c1Stholo status. 1134e77048c1Stholo 1135e77048c1Stholo 1136e77048c1StholoFile: cvs.info, Node: checkout examples, Prev: checkout options, Up: checkout 1137e77048c1Stholo 1138e77048c1Stholocheckout examples 1139e77048c1Stholo----------------- 1140e77048c1Stholo 1141e77048c1Stholo Get a copy of the module `tc': 1142e77048c1Stholo 1143e77048c1Stholo $ cvs checkout tc 1144e77048c1Stholo 1145e77048c1Stholo Get a copy of the module `tc' as it looked one day ago: 1146e77048c1Stholo 1147e77048c1Stholo $ cvs checkout -D yesterday tc 1148e77048c1Stholo 1149e77048c1Stholo 1150e77048c1StholoFile: cvs.info, Node: commit, Next: diff, Prev: checkout, Up: CVS commands 1151e77048c1Stholo 1152e77048c1Stholocommit--Check files into the repository 1153e77048c1Stholo======================================= 1154e77048c1Stholo 1155e77048c1Stholo * Synopsis: commit [-lnRf] [-m 'log_message' | -F file] [-r 1156e77048c1Stholo revision] [files...] 1157e77048c1Stholo 1158e77048c1Stholo * Requires: working directory, repository. 1159e77048c1Stholo 1160e77048c1Stholo * Changes: repository. 1161e77048c1Stholo 1162e77048c1Stholo * Synonym: ci 1163e77048c1Stholo 1164e77048c1Stholo Use `commit' when you want to incorporate changes from your working 1165e77048c1Stholosource files into the source repository. 1166e77048c1Stholo 1167e77048c1Stholo If you don't specify particular files to commit, all of the files in 1168e77048c1Stholoyour working current directory are examined. `commit' is careful to 1169e77048c1Stholochange in the repository only those files that you have really changed. 1170e77048c1StholoBy default (or if you explicitly specify the `-R' option), files in 1171e77048c1Stholosubdirectories are also examined and committed if they have changed; 1172e77048c1Stholoyou can use the `-l' option to limit `commit' to the current directory 1173e77048c1Stholoonly. 1174e77048c1Stholo 1175e77048c1Stholo `commit' verifies that the selected files are up to date with the 1176e77048c1Stholocurrent revisions in the source repository; it will notify you, and 1177e77048c1Stholoexit without committing, if any of the specified files must be made 1178e77048c1Stholocurrent first with `update' (*note update::). `commit' does not call 1179e77048c1Stholothe `update' command for you, but rather leaves that for you to do when 1180e77048c1Stholothe time is right. 1181e77048c1Stholo 1182e77048c1Stholo When all is well, an editor is invoked to allow you to enter a log 1183e77048c1Stholomessage that will be written to one or more logging programs (*note 1184e77048c1Stholomodules::, and *note loginfo::) and placed in the RCS file inside the 1185e77048c1Stholorepository. This log message can be retrieved with the `log' command; 1186e77048c1Stholosee *Note log::. You can specify the log message on the command line 1187e77048c1Stholowith the `-m MESSAGE' option, and thus avoid the editor invocation, or 1188e77048c1Stholouse the `-F FILE' option to specify that the argument file contains the 1189e77048c1Sthololog message. 1190e77048c1Stholo 1191e77048c1Stholo* Menu: 1192e77048c1Stholo 1193e77048c1Stholo* commit options:: commit options 1194e77048c1Stholo* commit examples:: commit examples 1195e77048c1Stholo 1196