LOG
View logs with the Unity Version Control CLI.
Read time 3 minutesLast updated 9 months ago
Description
Gets info about revisions in changesets.
Usage
cm log [<csetspec> | <repspec>] [--from=<csetspec_from>] [--allbranches] [--ancestors] [--csformat=<str_format>] [--itemformat=<str_format>] [--dateformat=<str_date_format>] [--xml[=<output_file>]] [--encoding=<name>] [--repositorypaths | --fullpaths | --fp]
Options
Option / Argument | Description |
|---|---|
| Lists all the changes made in every changeset from the changeset specification |
| Shows information about the changesets created in a specified interval, for all the branches where those changesets were created. |
| Shows information about the reachable changesets by following the parent and merge links for the given changeset ( |
| Retrieves the changeset info in a specific format. See Remarks for more info. This option cannot be combined with |
| Retrieves the item info in a specific format. See Remarks for more info. This option cannot be combined with |
| Sets the output format to print dates. |
| Prints the output in XML format to the standard output. It is possible to specify an output file. This option cannot be combined with |
| Used with the |
| Force printing full workspace paths for files and directories when possible. |
| Prints repository paths (server paths) instead of workspace paths. (This option overrides the |
| Returns all changes made in the specified changeset. (Use |
| Returns all changes made in the specified repository. (Use |
Help
Remarks
- If neither 'csetspec' nor option is specified, the command shows information about every changeset created within the last month in every branch.
- If only the option is included, the command shows the information about every changeset from that specified changeset to the last changeset in the branch where the changeset was created.
--from - If the option appears without an interval, the command retrieves the same information as it would do if only 'csetspec' was specified.
--allbranches - If the is used, the output contains information from the 'csetspec_from'+1 on.
--from - The repository used to show the changeset information is the one loaded in the path where the command executes on.
This command accepts a format string for the items () and a format string for the changesets ().
--itemformat--csformatThe output parameters of --csformat
are the following
--csformatOption / Argument | Description |
|---|---|
| Inserts a tab space. |
| Inserts a new line. |
| Changeset number. |
| Branch where the changeset was created. |
| Date of the changeset. |
| Owner of the changeset. |
| Comment of the changeset. |
| Items involved in the changeset. |
| Repository where the changeset exists. |
| Server name. |
The output parameters of --itemformat
are the following
--itemformatOption / Argument | Description |
|---|---|
| Inserts a tab space. |
| Inserts a new line. |
| Item path. |
| Branch where the changeset was created. |
| Date of the changeset. |
| Owner of the changeset. |
| Prints the short format for the status. See below. |
| Prints the long format for the status. See below. |
Short format and its corresponding long format
Option / Argument | Description |
|---|---|
| Added |
| Deleted |
| Moved |
| Changed |
These are valid output strings
--csformat="{newline} Changeset {changesetid} created on {date}; {tab} changed items: {items}."--itemformat="{newline} The item {path} was changed in the branch {branch}."
Date format parameters (--dateformat
)
--dateformatTo specify the output format in which dates will be printed. See the supported formats specified at:
Examples
cm log
(Shows information about every changeset created in the last month in every branch.)
cm log cs:16
(Shows information about the changes done in the changeset 16 in the branch where the changeset was created.)
cm log cs:16 --csformat="{newline}Changeset {changesetid} created on {date};{tab} changed items: {items}."
(Shows the information in the specified format.)
cm log --from=cs:20 cs:50
(Shows the information about every revision contained in every changeset from the changeset 21 to the changeset 50.)
cm log --from=cs:20 cs:50 --allbranches
(Shows the information about every revision contained in every changeset from the changeset 21 to the changeset 50 in every branch of the repository.)
cm log rep:myrep@localhost:8084
(Shows information about the changes done in the specified repository. No workspace is required to run the command.)
cm log --from=cs:20@rep:mainRep@localhost:8084
(Shows the information about every revision contained in every changeset from the changeset 21. No workspace is required to run the command, because the full changeset spec was specified.)