history of a renamed file
Given a repo that contains a file x.c
that got renamed fromsome/path/x.c
tonew/location/x.c
Is it possible (ideally with gitk) to view the complete history of what is now new/location/x.c *including* the history of changes that occurred when it stil was some/path/x.c? When I say "gitk new/location/x.c" I get just the changes made starting with the rename.
When I call "gitk" and look for the changeset, the rename is detected, though. Therefore I hope that it is somehow possible to obtain the complete file-specific history without truncation at renames.
Any ideas?
Thank you, best regards
Christoph
Quoted 15 lines · Christoph Duelli
Given a repo that contains a file
x.c
that got renamed from
some/path/x.c
to
new/location/x.cIs it possible (ideally with gitk) to view the complete history of what is now
new/location/x.c*including* the history of changes that occurred when it stil wassome/path/x.c?
When I say "gitknew/location/x.c" I get just the changes made starting with the rename.
When I call "gitk" and look for the changeset, the rename is detected, though. Therefore I hope that it is somehow possible to obtain the complete file-specific history without truncation at renames.
Quoted 1 line
Any ideas?
Try --follow option, see git-log(1), although I'm not sure if gitk supports it (it should).
Signature · 3 lines
Jakub Narebski Poland ShadeHawk on #git
Jakub Narebski wrote (2008-04-23 06:25 -0700):
Quoted 8 lines
Quoted 3 lines · Christoph Duelli
Is it possible (ideally with gitk) to view the complete history of what is now
new/location/x.c*including* the history of changes that occurred when it stil wassome/path/x.c?Try --follow option, see git-log(1), although I'm not sure if gitk supports it (it should).
gitk certainly accepts '--follow' but the option does not work as expected. For example try
gitk --follow -- utf8.c
in the Git repository and get surprised. :-)
I noticed the problem two weeks ago and Adam Simpkins elaborated it a bit. See http://thread.gmane.org/gmane.comp.version-control.git/79008
Quoted 17 lines · Jakub Narebski
Quoted 15 lines · Christoph Duelli
Given a repo that contains a file
x.c
that got renamed from
some/path/x.c
to
new/location/x.cIs it possible (ideally with gitk) to view the complete history of what is now
new/location/x.c*including* the history of changes that occurred when it stil wassome/path/x.c?
When I say "gitknew/location/x.c" I get just the changes made starting with the rename.
When I call "gitk" and look for the changeset, the rename is detected, though. Therefore I hope that it is somehow possible to obtain the complete file-specific history without truncation at renames.
Quoted 4 lines
Quoted 1 line
Any ideas?
Try --follow option, see git-log(1), although I'm not sure if gitk supports it (it should).
Works, thank you!
Signature · 1 line
Christoph Duelli