Word-by-word blame/annotate in version control?

Is it possible to reconstruct a word-by-word history in version control? Ideally, I’d like to do is something like 1) I indicate the range of lines of interest, 2) have the program figure out the corresponding line numbers in previous versions, as code often moved up or down between versions (potentially limiting the range of versions, say since revision 19, or since a week ago), 3) print out a word-by-word history, either the versions that groups of words were last changed, or the authors by which groups of words were changed. So it’s kind of like svn blame or git blame in a word-by-word level.

Failing that, are there tools that can do #1 and #2 above? That is, 1) I indicate the range of lines of interest, 2) have the program figure out the corresponding line numbers in previous versions, 3) the program would print out the history of these lines (when there were changes).

  • sed: parse git --line-porcelain output
  • git doesn't show where code was removed
  • git blame - ignore uncommitted changes
  • Is there a blame/annotate for 'MKS Source Integrity'?
  • Merge/diff tool that can show authors (supports blame or annotate) in files under version control
  • How to 'git blame' on the remote-side repository?
  • Either svn or git would be really helpful for me.

  • Git clone command stuck at "Cloning into 'repo'
  • using gitosis for GIT
  • Is it possible to Git merge / push using Jenkins pipeline
  • Merging branch back with clean history
  • cent os bash unrecognized option --system on adduser command
  • git remote merge commit causing false dependencies in gerrit
  • One Solution collect form web for “Word-by-word blame/annotate in version control?”

    I looked for something like this and ended up hacking up my own solution. You can find it here:

    https://github.com/d33tah/wordblame

    Basically, it creates a new repository directory in which all spaces are replaced by a newline and unique string signalling that there was a space. Then, “git blame” is executed and the result is reinterpreted.

    Git Baby is a git and github fan, let's start git clone.