0

There is any command/package that allows me to move back and forth through the vc history of a file, updating the buffer to display the previous/next revision of that file?

Let's say I have a file with 3 commits/versions, and I'm viewing the current "version 3" of the file. Then using the go-back and go-fwd commands should work like this:

  • go-back -> update buffer with version 2
  • go-back -> update buffer with version 1
  • go-fwd -> update buffer with version 2

etc...

3
  • 1
    Please write more clearly, without using needless abbreviations or meaningless phrases like "between the git log" (between the git log and what? Did you even mean the git log?!).
    – phils
    Dec 12, 2023 at 6:26
  • feels hard to be more clear. between versions. btw 1 & 2 , 2 & 3 etc
    – Math
    Dec 12, 2023 at 20:40
  • 1
    Then please compare emacs.stackexchange.com/posts/79784/revisions for future reference. Clarity is everything when you're asking questions. You should want to ensure that your question is as easily-comprehensible as possible.
    – phils
    Dec 12, 2023 at 23:15

1 Answer 1

1

You can give git-timemachine a try.

According to the Commentary section of the package it may do what you are after:

;;; Use git-timemachine to browse historic versions of a file with p
;;; (previous) and n (next).
2
  • seems what Im seeking. ty !
    – Math
    Dec 12, 2023 at 20:40
  • Nice. If so, please mark the answer as accepted so to help other readers in the future. Dec 13, 2023 at 8:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.