Module: kamailio Branch: master Commit: 888f8d6bb159408caf14360eb98ed5ff0bb52a78 URL: https://github.com/kamailio/kamailio/commit/888f8d6bb159408caf14360eb98ed5ff...
Author: Olle E. Johansson oej@edvina.net Committer: Olle E. Johansson oej@edvina.net Date: 2015-02-11T21:01:21+01:00
uac_redirect Rename module file #82
---
Added: modules/uac_redirect/uac_redirect.c Removed: modules/uac_redirect/redirect.c
---
Diff: https://github.com/kamailio/kamailio/commit/888f8d6bb159408caf14360eb98ed5ff... Patch: https://github.com/kamailio/kamailio/commit/888f8d6bb159408caf14360eb98ed5ff...
You should use
git mv ...
in order to preserve the history of the file.
Removing existing one and adding it is losing that.
Cheers, Daniel On 11/02/15 21:13, Olle E. Johansson wrote:
Module: kamailio Branch: master Commit: 888f8d6bb159408caf14360eb98ed5ff0bb52a78 URL: https://github.com/kamailio/kamailio/commit/888f8d6bb159408caf14360eb98ed5ff...
Author: Olle E. Johansson oej@edvina.net Committer: Olle E. Johansson oej@edvina.net Date: 2015-02-11T21:01:21+01:00
uac_redirect Rename module file #82
Added: modules/uac_redirect/uac_redirect.c Removed: modules/uac_redirect/redirect.c
Diff: https://github.com/kamailio/kamailio/commit/888f8d6bb159408caf14360eb98ed5ff... Patch: https://github.com/kamailio/kamailio/commit/888f8d6bb159408caf14360eb98ed5ff...
sr-dev mailing list sr-dev@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev
On 11 Feb 2015, at 21:16, Daniel-Constantin Mierla miconda@gmail.com wrote:
You should use
git mv ...
in order to preserve the history of the file.
Removing existing one and adding it is losing that.
I did use "git mv"
$ git commit [master e0a20eb] app_java Rename module interface file 8 files changed, 6 insertions(+), 6 deletions(-) rename modules/app_java/{java_mod.c => app_java_mod.c} (100%) rename modules/app_java/{java_mod.h => app_java_mod.h} (100%)
It is weird that the mail message shows something else...
/O
Cheers, Daniel On 11/02/15 21:13, Olle E. Johansson wrote:
Module: kamailio Branch: master Commit: 888f8d6bb159408caf14360eb98ed5ff0bb52a78 URL: https://github.com/kamailio/kamailio/commit/888f8d6bb159408caf14360eb98ed5ff...
Author: Olle E. Johansson oej@edvina.net Committer: Olle E. Johansson oej@edvina.net Date: 2015-02-11T21:01:21+01:00
uac_redirect Rename module file #82
Added: modules/uac_redirect/uac_redirect.c Removed: modules/uac_redirect/redirect.c
Diff: https://github.com/kamailio/kamailio/commit/888f8d6bb159408caf14360eb98ed5ff... Patch: https://github.com/kamailio/kamailio/commit/888f8d6bb159408caf14360eb98ed5ff...
sr-dev mailing list sr-dev@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev
-- Daniel-Constantin Mierla http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda Kamailio World Conference, May 27-29, 2015 Berlin, Germany - http://www.kamailioworld.com
On 11/02/15 21:24, Olle E. Johansson wrote:
On 11 Feb 2015, at 21:16, Daniel-Constantin Mierla miconda@gmail.com wrote:
You should use
git mv ...
in order to preserve the history of the file.
Removing existing one and adding it is losing that.
I did use "git mv"
$ git commit [master e0a20eb] app_java Rename module interface file 8 files changed, 6 insertions(+), 6 deletions(-) rename modules/app_java/{java_mod.c => app_java_mod.c} (100%) rename modules/app_java/{java_mod.h => app_java_mod.h} (100%)
It is weird that the mail message shows something else...
It seems to be git behaviour when the change is consistent. Found on the net that the rename itself should be a single commit in order to preserve history in 'git log'. See:
- https://coderwall.com/p/_csouq/renaming-and-changing-files-in-git-without-lo...
Even with a rename as part of a bigger change, history can be seen when using --follow for git-log, like:
git log --follow modules/uac_redirect/uac_redirect.c
But git web viewer don't do that usually. Therefore, it is better to do just the rename as single commit. Eventually will work fine to see all history.
Cheers, Daniel
On 11/02/15 21:42, Daniel-Constantin Mierla wrote:
On 11/02/15 21:24, Olle E. Johansson wrote:
On 11 Feb 2015, at 21:16, Daniel-Constantin Mierla miconda@gmail.com wrote:
You should use
git mv ...
in order to preserve the history of the file.
Removing existing one and adding it is losing that.
I did use "git mv"
$ git commit [master e0a20eb] app_java Rename module interface file 8 files changed, 6 insertions(+), 6 deletions(-) rename modules/app_java/{java_mod.c => app_java_mod.c} (100%) rename modules/app_java/{java_mod.h => app_java_mod.h} (100%)
It is weird that the mail message shows something else...
It seems to be git behaviour when the change is consistent. Found on the net that the rename itself should be a single commit in order to preserve history in 'git log'. See:
https://coderwall.com/p/_csouq/renaming-and-changing-files-in-git-without-lo...
Even with a rename as part of a bigger change, history can be seen when using --follow for git-log, like:
git log --follow modules/uac_redirect/uac_redirect.c
But git web viewer don't do that usually. Therefore, it is better to do just the rename as single commit. Eventually will work fine to see all history.
Looks like that doesn't work either -- digging in web more revealed:
- https://git.wiki.kernel.org/index.php/GitFaq#Why_does_Git_not_.22track.22_re...
Anyhow, git log --follow should be good enough. Also, git-blame does --follow automatically.
I guess doing all in one commit is ok, with same results as split commit for just file rename.
Cheers, Daniel