0072-0073.html
来自「linux-unix130.linux.and.unix.ebooks130 l」· HTML 代码 · 共 303 行
HTML
303 行
<HTML>
<HEAD>
<TITLE>Linux Complete Command Reference:User Commands:EarthWeb Inc.-</TITLE>
</HEAD>
<META NAME="ROBOTS" CONTENT="NOINDEX, NOFOLLOW">
<SCRIPT>
<!--
function displayWindow(url, width, height) {
var Win = window.open(url,"displayWindow",'width=' + width +
',height=' + height + ',resizable=1,scrollbars=yes');
}
//-->
</SCRIPT>
</HEAD>
-->
<!-- ISBN=0672311046 //-->
<!-- TITLE=Linux Complete Command Reference//-->
<!-- AUTHOR=Red Hat//-->
<!-- PUBLISHER=Macmillan Computer Publishing//-->
<!-- IMPRINT=Sams//-->
<!-- CHAPTER=01 //-->
<!-- PAGES=0001-0736 //-->
<!-- UNASSIGNED1 //-->
<!-- UNASSIGNED2 //-->
<P><CENTER>
<a href="0069-0071.html">Previous</A> | <a href="../ewtoc.html">Table of Contents</A> | <a href="0074-0077.html">Next</A></CENTER></P>
<A NAME="PAGENUM-72"><P>Page 72</P></A>
<P><B>
OPTIONS
</B></P>
<TABLE>
<TR><TD>
-r[rev]
</TD><TD>
Retrieves the latest revision whose number is less than or equal to
rev. If rev indicates a branch rather than a revision, the latest revision on that branch is retrieved. If
rev is omitted, the latest revision on the default branch is retrieved; see the
_b option of rcs(1). If rev is $, co determines
the revision number from keyword values in the working file. Otherwise, a revision is composed of
one or more numeric or symbolic fields separated by periods. If
rev begins with a period, then the default branch (normally the trunk) is prepended to it. If
rev is a branch number followed by a period, then the latest revision on that branch is used. The numeric equivalent of a symbolic field
is specified with the _n option of the commands ci(1) and
rcs(1).
</TD></TR><TR><TD>
_l[rev]
</TD><TD>
Same as -r, except that it also locks the retrieved revision for the caller.
</TD></TR><TR><TD>
_u[rev]
</TD><TD>
Same as -r, except that it unlocks the retrieved revision if it was locked by the caller. If
rev is omitted, _u retrieves the revision locked by the caller, if there is one; otherwise, it retrieves the
latest revision on the default branch.
</TD></TR><TR><TD>
_f[rev]
</TD><TD>
Forces the overwriting of the working file; useful in connection with
_q. (See also "File Modes," later in this manual page.)
</TD></TR><TR><TD>
_kkv
</TD><TD>
Generate keyword strings using the default form, for example,
$Revision: 5.13 $ for the Revision keyword. A locker's name is inserted in the value of the
Header, Id, and Locker keyword strings only as a file is being locked, that is, by
ci _l and co _l. This is the default.
</TD></TR><TR><TD>
_kkvl
</TD><TD>
Like _kkv, except that a locker's name is always inserted if the given revision is currently locked.
</TD></TR><TR><TD>
_kk
</TD><TD>
Generate only keyword names in keyword strings; omit their values. (See "Keyword
Substitution," later in this manual page.) For example, for the
Revision keyword, generate the string $Revision$ instead of
$Revision: 5.13 $. This option is useful to ignore differences due to keyword
substitution when comparing different revisions of a file. Log messages are inserted after
$Log$ keywords even if _kk is specified, since this tends to be more useful when merging changes.
</TD></TR><TR><TD>
_ko
</TD><TD>
Generate the old keyword string, present in the working file just before it was checked in.
For example, for the Revision keyword, generate the string
$Revision: 1.1 $ instead of $Revision: 5.13 $ if that is how the string appeared when the file was checked in. This can be useful for file
formats that cannot tolerate any changes to substrings that happen to take the form of keyword strings.
</TD></TR><TR><TD>
_kb
</TD><TD>
Generate a binary image of the old keyword string. This acts like
_ko, except it performs all working file input and output in binary mode. This makes little difference on POSIX and
UNIX hosts, but on DOS-like hosts one should use rcs -i
_kb to initialize an RCS file normally refuses to merge files when
_kb is in effect.
</TD></TR><TR><TD>
_kv
</TD><TD>
Generate only keyword values for keyword strings. For example, for the
Revision keyword, generate the string 5.13 instead of
$Revision: 5.13 $. This can help generate files in programming
languages where it is hard to strip keyword delimiters like
$Revision: $ from a string. However, further keyword substitution cannot be performed once the keyword names are removed, so this
option should be used with care. Because of this danger of losing keywords, this option cannot
be combined with _l, and the owner write permission of the working file is turned off; to edit the
file later, check it out again without _kv.
</TD></TR><TR><TD>
_p[rev]
</TD><TD>
Prints the retrieved revision on the standard output rather than storing it in the working file.
This option is useful when co is part of a pipe.
</TD></TR><TR><TD>
_q[rev]
</TD><TD>
Quiet mode; diagnostics are not printed.
</TD></TR><TR><TD>
_I[rev]
</TD><TD>
Interactive mode; the user is prompted and questioned even if the standard input is not a terminal.
</TD></TR><TR><TD>
_ddate
</TD><TD>
Retrieves the latest revision on the selected branch whose checkin date/time is less than or equal
to date. The date and time can be given in free format. The time zone
LT stands for local time; other common time zone names are understood. For example, the following dates are equivalent if
local time is January 11, 1990, 8 p.m. Pacific Standard Time, eight hours west of Coordinated
Universal Time (UTC):
</TD></TR></TABLE>
<TABLE>
<TR><TD>
</TD><TD>
8:00 PM lt
</TD><TD>
</TD></TR><TR><TD>
</TD><TD>
4:00 AM, Jan. 12, 1990
</TD><TD>
Default is UTC
</TD></TR></TABLE>
<A NAME="PAGENUM-73"><P>Page 73</P></A>
<TABLE>
<TR><TD>
</TD><TD>
1990-01-12 04:00:00+00
</TD><TD>
ISO 8601 (UTC)
</TD></TR><TR><TD>
</TD><TD>
1990-01-11 20:00:00_08
</TD><TD>
ISO 8601 (local time)
</TD></TR><TR><TD>
</TD><TD>
1990/01/12 04:00:00
</TD><TD>
Traditional RCS format
</TD></TR><TR><TD>
</TD><TD>
Thu Jan 11 20:00:00 1990 LT
</TD><TD>
Output of ctime(3) + LT
</TD></TR><TR><TD>
</TD><TD>
Thu Jan 11 20:00:00 PST 1990
</TD><TD>
Output of date(1)
</TD></TR><TR><TD>
</TD><TD>
Fri Jan 12 04:00:00 GMT 1990
</TD><TD>
</TD></TR><TR><TD>
</TD><TD>
Thu, 11 Jan 1990 20:00:00 _0800
</TD><TD>
Internet RFC 822
</TD></TR><TR><TD>
</TD><TD>
12-January-1990, 04:00 WET
</TD><TD>
</TD></TR><TR><TD>
</TD></TR></TABLE>
<P>Most fields in the date and time can be defaulted. The default time zone is normally UTC, but this can be overridden by
the _z option. The other defaults are determined in the order year, month, day, hour, minute, and second (most to
least significant). At least one of these fields must be provided. For omitted fields that are of higher significance than the
highest provided field, the time zone's current values are assumed. For all other omitted fields, the lowest possible values
are assumed. For example, without _z, the date 20, 10:30 defaults to 10:30:00 UTC of the 20th of the UTC time zone's
current month and year. The date/time must be quoted if it contains spaces.
</P>
<TABLE>
<TR><TD>
_M[rev]
</TD><TD>
Sets the modification time on the new working file to be the date of the retrieved revision. Use
this option with care; it can confuse make(1).
</TD></TR><TR><TD>
_sstate
</TD><TD>
Retrieves the latest revision on the selected branch whose state is set to state.
</TD></TR><TR><TD>
_T
</TD><TD>
Preserves the modification time on the RCS file even if the RCS file changes because a lock
is added or removed. This option can suppress extensive recompilation caused by a
make(1) dependency of some other copy of the working file on the RCS file. Use this option with care; it
can suppress recompilation even when it is needed, in other words, when the change of lock
would mean a change to keyword strings in the other working file.
</TD></TR><TR><TD>
_w[login]
</TD><TD>
Retrieves the latest revision on the selected branch that was checked in by the user with login
name login. If the argument login is omitted, the caller's login is assumed.
</TD></TR><TR><TD>
_jjoinlist
</TD><TD>
Generates a new revision which is the join of the revisions on
joinlist. This option is largely made obsolete by
rcsmerge(1), but is retained for backwards compatibility.
</TD></TR><TR><TD>
</TD><TD>
The joinlist is a comma-separated list of pairs of the form
rev2:rev3, where rev2 and rev3 are (symbolic or numeric) revision numbers. For the initial such pair,
rev1 denotes the revision selected by the options
_f, _w. For all other pairs, rev1 denotes the revision generated by the previous
pair. (Thus, the output of one join becomes the input to the next.)
</TD></TR><TR><TD>
</TD><TD>
For each pair, co joins revisions rev1 and
rev3 with respect to rev2. This means that all changes
that transform rev2 into rev1 are applied to a copy of
rev3. This is particularly useful if rev1 and rev3 are the ends of two branches that have
rev2 as a common ancestor. If rev1<rev2<rev3 on the
same branch, joining generates a new revision which is like
rev3, but with all changes that lead from rev1 to
rev2 undone. If changes from rev2 to rev1 overlap with changes from
rev2 to rev3, co reports overlaps as described in
merge(1).
</TD></TR><TR><TD>
</TD><TD>
For the initial pair, rev2 can be omitted. The default is the common ancestor. If any of
the arguments indicate branches, the latest revisions on those branches are assumed. The options
_l and _u lock or unlock rev1.
</TD></TR><TR><TD>
_V
</TD><TD>
Prints RCS's version number.
</TD></TR><TR><TD>
_Vn
</TD><TD>
Emulates RCS version n, where n can be 3, 4, or 5. This can be useful when interchanging
RCS files with others who are running older versions of RCS. To see which version of RCS
your correspondents are running, have them invoke rcs
_V; this works with newer versions of RCS. If it doesn't work, have them invoke
rlog on an RCS file; if none of the first few lines of output
contain the string branch:, it is version 3; if the dates' years have just two digits, it is version 4; otherwise,
it is version 5. An RCS file generated while emulating version 3 loses its default branch. An
RCS revision generated while emulating version 4 or earlier has a timestamp that is off by up to
13 hours. A revision extracted while emulating version 4 or earlier contains abbreviated dates of
the form yy/mm/dd and can also contain different whitespace and line prefixes in the substitution
for $Log$.
</TD></TR></TABLE>
<P><CENTER>
<a href="0069-0071.html">Previous</A> | <a href="../ewtoc.html">Table of Contents</A> | <a href="0074-0077.html">Next</A></CENTER></P>
</td>
</tr>
</table>
<!-- begin footer information -->
</body></html>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?