einpoklum
einpoklum

Reputation: 131521

What's the ClearCase equivalent of git log on a file?

With git log my_file, I can see a list of commits (or rather a forest of branches and commits on them) involving my_file, inclduing dates and commit comments. How do I do this with ClearCase?

Upvotes: 1

Views: 305

Answers (2)

VonC
VonC

Reputation: 1323793

The two commands to consider are:

  • cleartool lshistory which applies to:

    • a pname, including an extended path name of the version you need
    • an object selector: for example, lbtype:V3.0
  • cleartool lsvtree, which is closer to a git log --all --branches, which lists part or all of the version tree of one or more elements.
    By default, the listing includes all branches of an element's version tree except for obsolete branches

Upvotes: 1

einpoklum
einpoklum

Reputation: 131521

Use:

cleartool lshistory /path/to/file

for that. Output will have one line for every action, with the fields:

  1. Date take (or time if it's recent)
  2. Acting user
  3. Action description (e.g. "create branch")
  4. File location + @@ + revision/branch specification (e.g. foo@@/bar/LATEST)

Enjoy.

Upvotes: 0

Related Questions