Hi,

On 10/22/2016 12:27 AM, Nikita Borodikhin wrote:
== relative revisions - history analysis ==

In Fossil there is no way to refer to a parent of a revision, with the 
exception the parent of checked out revision.
Can you give examples of why you’d need to do this?  I mean, what’s wrong with 
“fossil up 1234abcd” between each diff?  Is the problem simply that it changes 
working directory contents?  I don’t mean to trivialize that if so, I just want 
to be clear on what you see as the problem.

The Fossil web UI has a semi-hidden feature to do this.  Just click two bubbles 
in the timeline and you get a diff page showing the changes between those two 
versions.

Reviewing the history of changes in a branch. Sometimes when you're looking into history of a file, what you need is to go into the history one commit at a time. After you found the last revision of the branch, you can check three commits without having to copy three revision hashes:
git show sha1
git show sha1^
git show sha1^^

UI does not need this, because you point to the revision visually.

Sometimes it is hard to remember what is the actual use case because you use the features very organically.

I just realized my use case for this feature is a bit different. I often use it analyzing one file and trying to recover what it looked like some time ago. Even more specific, how its part looked like back then, and how it evolved. I came up with the sequence of commands to go through "history of file part backward":

 * git annotate <file> (annotated file is opened in pager)
 * scroll it to the place I am interested in
 * copy revision number (one or several cases I use mouse in terminal)
 * close pager
 * git annotate file <mouse-paste revision number>^
 * scroll pager to that place

I do the same with svn, but for svn, instead of "^", I subtract one from the copied revision number.


Nikita
_______________________________________________
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to