The sitehist command displays the transaction history of non-depot specific site information such as stream acls, users and group membership.-c <comment-string>
Display only transaction(s) whose comments contain the specified string. (The string matching is case-insensitive.) Enclose the string in quotes to ensure that sitehist interprets it as a single command-line argument.-f <format(s)>t: ("transaction") Display just the header line, including the transaction number.x: ("XML") Display results in XML format.-k <transaction-kind>-u <principal-name>-t <time-spec>[ .<count> ]-t <time-spec> - <time-spec>[ .<count> ]
• Time in <"YYYY/MM/DD HH:MM:SS"> format, "2007/08/07 20:27:15", for example. Note that you must use quotes when specifying time-spec as YYYY/MM/DD HH:MM:SS to ensure that the entire argument is interpreted by the command shell as a single token.
• Time keyword: now
•
• Transaction number keyword: highestWhen using the –t option, take into account the possibility of a timewarp. The AC_SYNC environment variable (see AccuRev User Preferences) determines how a timewarp will be handled. See also section System Clock Synchronization of the AccuRev Administrator’s Guide.By default, sitehist displays the entire transaction history of the site. The various forms of the -t option restrict the display to a single transaction, or to a range of transactions. Each variant involves one or two time-specs. A single time-spec means "the transaction that took place at this time" or "the most recent transaction that took place before this time". Two time-specs define an interval; sitehist reports all the transactions in the interval.> accurev sitehist -t now -k mkuser
transaction 10; mkuser; 2016/03/15 16:14:09; user: u1
new; id: 10; name: u5_nopass; kind: full> accurev sitehist -t now -k mkuser -fxThe <User> element details the number, name and kind of user that was created by the mkuser transaction. A transaction's timestamp (time attribute of the XML element <transaction>) is reported as the number of seconds since Jan. 1, 1970 UTC. Special Field Types on page 264 describes a technique for converting this timestamp into a human-readable string.The user attribute of the <transaction> element displays the name of the user who issued the mkuser transaction.Display information on the most recent mkgroup site transaction:> accurev sitehist -t now -k mkgroup -fx
<?xml version="1.0" encoding="utf-8"?>
<AcResponse
Command="sitehist"
TaskId="1302">
<transaction
id="29"
type="mkgroup"
time="1458072851"
user="u1">
<Group
Info="new"
Number="17"
Name="gmeta2"/>
</transaction>
</AcResponse>> accurev sitehist -t now -k chuser -fx
<?xml version="1.0" encoding="utf-8"?>
<AcResponse
Command="sitehist"
TaskId="1305">
<transaction
id="51"
type="chuser"
time="1458073304"
user="u1">
<User
Info="old"
Number="2"
Name="u2"
Kind="full"/>
<User
Info="new"
Number="2"
Name="testuser2"
Kind="full"/>
</transaction>
</AcResponse>Notice that there are two user elements in the transaction. The record with the Info="old" attribute contains the number, name and kind of user before the changes made by the chuser command. The element with the Info="new" attribute contains the new number, name and kind. Notice that the name changed from "u2" to "testuser2".Display information on the most recent set_acl transaction:> accurev sitehist -t now -k set_acl -fx
<?xml version="1.0" encoding="utf-8"?>
<AcResponse
Command="sitehist"
TaskId="1306">
<transaction
id="50"
type="set_acl"
time="1458072889"
user="u1">
<Acl
action="set"
depot="d1"
stream=""
user="gmeta2"
allow_access="yes"
inheritable="yes"/>
</transaction>
</AcResponse>
Micro Focus |