[BACK]Return to co.1 CVS log [TXT][DIR] Up to [local] / src / usr.bin / rcs

Annotation of src/usr.bin/rcs/co.1, Revision 1.25

1.25    ! jmc         1: .\"    $OpenBSD: co.1,v 1.24 2006/04/19 11:08:23 jmc Exp $
1.1       xsa         2: .\"
                      3: .\" Copyright (c) 2005 Xavier Santolaria <xsa@openbsd.org>
                      4: .\" All rights reserved.
                      5: .\"
                      6: .\" Permission to use, copy, modify, and distribute this software for any
                      7: .\" purpose with or without fee is hereby granted, provided that the above
                      8: .\" copyright notice and this permission notice appear in all copies.
                      9: .\"
                     10: .\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
                     11: .\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
                     12: .\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
                     13: .\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
                     14: .\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
                     15: .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
                     16: .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
1.2       jmc        17: .Dd October 03, 2005
1.1       xsa        18: .Dt CO 1
                     19: .Os
                     20: .Sh NAME
                     21: .Nm co
                     22: .Nd check out RCS revisions
                     23: .Sh SYNOPSIS
                     24: .Nm
                     25: .Bk -words
1.15      xsa        26: .Op Fl TV
1.7       niallo     27: .Op Fl d Ns Ar date
1.13      xsa        28: .Op Fl f Ns Op Ar rev
                     29: .Op Fl I Ns Op Ar rev
1.7       niallo     30: .Op Fl k Ns Ar mode
                     31: .Op Fl l Ns Op Ar rev
1.10      niallo     32: .Op Fl M Ns Op Ar rev
1.9       niallo     33: .Op Fl p Ns Op Ar rev
1.13      xsa        34: .Op Fl q Ns Op Ar rev
1.7       niallo     35: .Op Fl r Ns Op Ar rev
                     36: .Op Fl s Ns Ar state
                     37: .Op Fl u Ns Op Ar rev
1.17      xsa        38: .Op Fl w Ns Op Ar user
1.7       niallo     39: .Op Fl x Ns Ar suffixes
                     40: .Op Fl z Ns Ar tz
1.23      jmc        41: .Ar
1.1       xsa        42: .Ek
                     43: .Sh DESCRIPTION
1.21      jmc        44: The
1.1       xsa        45: .Nm
1.21      jmc        46: program is used to check out revisions from RCS files.
1.23      jmc        47: .Pp
                     48: When a file is checked out,
                     49: a copy is taken from the RCS repository,
                     50: minus its RCS information,
                     51: and placed in the current working directory.
                     52: Files may be checked out as the most recent revision
                     53: or according to a specific revision,
                     54: using the
                     55: .Fl r
                     56: option.
                     57: .Pp
                     58: Files are checked out in one of two possible modes:
                     59: unlocked (the default) or locked (using the
                     60: .Fl l
                     61: option).
                     62: In unlocked mode, any user may check out the file for reading.
                     63: If changes are to be made to a file though,
                     64: it will have to be locked using the
                     65: .Fl l
                     66: option.
                     67: During this time,
                     68: no other users may check out the file whilst it is locked.
                     69: .Pp
1.25    ! jmc        70: Files may be selected by revision or,
        !            71: where no revision is specified,
        !            72: the latest revision of the default branch is used.
        !            73: Revisions are specified either by using the
        !            74: .Fl r
        !            75: option or
        !            76: by appending the revision number to any option that supports it.
        !            77: .Pp
1.23      jmc        78: .Nm
                     79: also supports
                     80: keyword substitution \(en
                     81: see the
1.24      jmc        82: .Xr rcs 1
1.23      jmc        83: man page for more information.
1.1       xsa        84: .Pp
                     85: The following options are supported:
                     86: .Bl -tag -width Ds
1.7       niallo     87: .It Fl d Ns Ar date
1.1       xsa        88: Retrieve revision as of the latest revision no later than
                     89: .Ar date .
1.13      xsa        90: .It Fl f Ns Op Ar rev
1.1       xsa        91: Force the overwriting of the working file.
1.13      xsa        92: .It Fl I Ns Op Ar rev
1.1       xsa        93: Interactive mode.
1.7       niallo     94: .It Fl k Ns Ar mode
1.1       xsa        95: Specify the keyword substitution mode.
1.7       niallo     96: .It Fl l Ns Op Ar rev
1.1       xsa        97: The same as
                     98: .Fl r ,
1.2       jmc        99: but also locks the revision.
1.10      niallo    100: .It Fl M Ns Op Ar rev
1.2       jmc       101: Set the modification time of the file to the date of the
1.1       xsa       102: retrieved revision.
1.9       niallo    103: .It Fl p Ns Op Ar rev
                    104: Print the latest revision no later than
                    105: .Ar rev
                    106: to standard output.
1.14      jmc       107: .It Fl q Ns Op Ar rev
1.1       xsa       108: Be quiet about reporting.
1.7       niallo    109: .It Fl r Ns Op Ar rev
1.1       xsa       110: Retrieve the latest revision no later than
                    111: .Ar rev .
1.7       niallo    112: .It Fl s Ns Ar state
1.1       xsa       113: Retrieve revision of the specified
                    114: .Ar state
                    115: only.
1.19      xsa       116: .It Fl T
                    117: Preserve the modification time of RCS files.
1.7       niallo    118: .It Fl u Ns Op Ar rev
1.1       xsa       119: The same as
                    120: .Fl r ,
1.2       jmc       121: but also unlocks the retrieved revision if it was locked.
1.1       xsa       122: .It Fl V
                    123: Print RCS's version number.
1.17      xsa       124: .It Fl w Ns Op Ar user
1.1       xsa       125: Retrieve the latest revision which was checked in by the specified
                    126: .Ar user .
                    127: If the
                    128: .Ar user
1.2       jmc       129: argument is omitted, the login of the user issuing the command
1.1       xsa       130: is assumed.
1.7       niallo    131: .It Fl x Ns Ar suffixes
1.1       xsa       132: Specifies the suffixes for RCS files.
                    133: Suffixes should be separated by the
                    134: .Sq /
                    135: character.
1.7       niallo    136: .It Fl z Ns Ar tz
1.1       xsa       137: Specify the date output format in keyword substitution, and the
1.18      xsa       138: default time zone for
1.1       xsa       139: .Ar date
                    140: used in the
                    141: .Fl d
                    142: option.
                    143: .El
                    144: .Sh ENVIRONMENT
                    145: .Bl -tag -width RCSINIT
                    146: .It Ev RCSINIT
                    147: If set, this variable should contain a list of space-delimited options that
                    148: are prepended to the argument list.
                    149: .El
1.11      xsa       150: .Sh EXAMPLES
                    151: Retrieve the latest revision of file
                    152: .Pa foo.c
                    153: and lock it for further editing:
                    154: .Pp
                    155: .Dl $ co -l foo.c
                    156: .Pp
                    157: Retrieve revision 1.5 of file
                    158: .Pa foo.c :
                    159: .Pp
                    160: .Dl $ co -r1.5 foo.c
1.1       xsa       161: .Sh SEE ALSO
                    162: .Xr ci 1 ,
1.4       jmc       163: .Xr ident 1 ,
1.1       xsa       164: .Xr rcs 1 ,
                    165: .Xr rcsclean 1 ,
                    166: .Xr rcsdiff 1 ,
1.8       xsa       167: .Xr rcsmerge 1 ,
1.6       xsa       168: .Xr rlog 1