Feature #35432
closedGit: View annotation prior to the change
Added by Go MAEDA about 3 years ago. Updated over 1 year ago.
0%
Description
The "Blame" view of GitHub and Gitlab has a feature called "View blame prior to this change". With the feature, you can easily jump to an older change of the line.
I think it would be useful if Redmine also has the feature. Currently, it requires some manual steps to see older changes in the "Annotate" view of Redmine.
Files
gitlab-view-blame-prior-to-this-change.png (124 KB) gitlab-view-blame-prior-to-this-change.png | Go MAEDA, 2021-06-22 10:00 | ||
35432.patch (6.09 KB) 35432.patch | Takenori TAKAKI, 2021-07-08 09:59 | ||
disp_link_to_prior.png (231 KB) disp_link_to_prior.png | Takenori TAKAKI, 2021-07-08 10:00 | ||
0001-Git-View-annotate-prior-to-the-change.patch (288 KB) 0001-Git-View-annotate-prior-to-the-change.patch | Go MAEDA, 2022-09-03 09:35 | ||
0001-Code-cleanup-of-RepositoriesController-annotate.patch (1.39 KB) 0001-Code-cleanup-of-RepositoriesController-annotate.patch | Go MAEDA, 2023-04-23 09:03 | ||
0002-Git-View-annotate-prior-to-the-change.patch (7.44 KB) 0002-Git-View-annotate-prior-to-the-change.patch | Go MAEDA, 2023-04-23 09:03 | ||
clipboard-202304301308-zmlp9.png (122 KB) clipboard-202304301308-zmlp9.png | Go MAEDA, 2023-04-30 06:08 | ||
def17b5f.png (18.3 KB) def17b5f.png | Robert Korulczyk, 2023-05-06 17:11 |
Related issues
Updated by Takenori TAKAKI about 3 years ago
- File 35432.patch 35432.patch added
- File disp_link_to_prior.png disp_link_to_prior.png added
I made a patch to display the link to prior revision.
The patch adds a link to "Annotate" view as follows
Updated by Go MAEDA about 3 years ago
- Target version set to Candidate for next major release
Updated by Mischa The Evil almost 3 years ago
- Subject changed from View annotate prior to the change to Git: View annotate prior to the change
+1 This is a real handy feature when browsing (Git) repositories a lot. Given the usability of this change I wonder if this is something that could be implemented (easily) for other SCMs (Hg, SVN, ...) too?!
Updated by Go MAEDA almost 3 years ago
Mischa The Evil wrote:
Given the usability of this change I wonder if this is something that could be implemented (easily) for other SCMs (Hg, SVN, ...) too?!
This feature is easy to implement in the Git adapter because `git blame -p` outputs the previous commit for the line, as shown in the "previous" like of the following sample.
However, `blame` / `annotate` subcommand of other SCMs such as subversion doesn't give the information of the previous change, so we have to find another way to get the previous change.
Since there are so many Git users these days, I think it is a good idea only for Git as a first step.
c91a4391d34b9bd97270d20f04aeb40ee64166a1 1 1 1 author Jean-Philippe Lang author-mail <jp_lang@yahoo.fr> author-time 1476985764 author-tz +0000 committer Jean-Philippe Lang committer-mail <jp_lang@yahoo.fr> committer-time 1476985764 committer-tz +0000 summary Set https back. previous 15460450bbe72a756015e16689bcafe5a6b1164b Gemfile filename Gemfile source 'https://rubygems.org' 9315039e0a95b0234b7736f359fc039550f45e08 2 2 1 author Jean-Philippe Lang author-mail <jp_lang@yahoo.fr> author-time 1329661846 author-tz +0000 committer Jean-Philippe Lang committer-mail <jp_lang@yahoo.fr> committer-time 1329661846 committer-tz +0000 summary Use Bundler for gem management (#5638). filename Gemfile
Updated by Go MAEDA about 2 years ago
- Target version changed from Candidate for next major release to 5.1.0
Setting the target version to 5.1.0.
Updated by Go MAEDA almost 2 years ago
- File 0001-Git-View-annotate-prior-to-the-change.patch 0001-Git-View-annotate-prior-to-the-change.patch added
Updated the patch for the current trunk r21799.
Updated by Go MAEDA over 1 year ago
- File 0001-Code-cleanup-of-RepositoriesController-annotate.patch 0001-Code-cleanup-of-RepositoriesController-annotate.patch added
- File 0002-Git-View-annotate-prior-to-the-change.patch 0002-Git-View-annotate-prior-to-the-change.patch added
I have updated the patch not to hard-code Repository::Git constant in app/views/repositories/annotate.html.erb.
Updated by Go MAEDA over 1 year ago
- File clipboard-202304301308-zmlp9.png clipboard-202304301308-zmlp9.png added
- Status changed from New to Closed
- Assignee set to Go MAEDA
- Resolution set to Fixed
Committed the patch in r22217 with slight modifications. Thank you for your contribution.
The annotate view of a Git repository now has "View annotation prior to this change" buttons.
Updated by Robert Korulczyk over 1 year ago
- File def17b5f.png def17b5f.png added
Go MAEDA wrote in #note-4:
However, `blame` / `annotate` subcommand of other SCMs such as subversion doesn't give the information of the previous change, so we have to find another way to get the previous change.
You don't really need to know revision of previous change for SVN. Since revisions in SVN are sequential numbers, you only need to decrease number of revision of given change and show annotations for this version. For example to see annotations prior r22231 for this file
you need to show annotations for revision 22230: https://www.redmine.org/projects/redmine/repository/svn/revisions/22230/annotate/trunk/app/views/repositories/revision.html.erb
Updated by Go MAEDA over 1 year ago
- Related to Feature #38526: Subversion support for "View annotation prior to this change" added
Updated by Go MAEDA over 1 year ago
Robert Korulczyk wrote in #note-9:
You don't really need to know revision of previous change for SVN. Since revisions in SVN are sequential numbers, you only need to decrease number of revision of given change and show annotations for this version.
Thank you for your suggestion. I have opened #38526 to implement this feature for Subversion.
Updated by Go MAEDA over 1 year ago
- Subject changed from Git: View annotate prior to the change to Git: View annotation prior to the change