webkit-patch setup-git-clone should set Git core editor to commit-log-editor
authordbates@webkit.org <dbates@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 10 Aug 2018 21:48:41 +0000 (21:48 +0000)
committerdbates@webkit.org <dbates@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 10 Aug 2018 21:48:41 +0000 (21:48 +0000)
https://bugs.webkit.org/show_bug.cgi?id=188473

Reviewed by Ryosuke Niwa.

Have "webkit-patch setup-git-clone" set the Git core editor to "perl Tools/Scripts/commit-log-editor --regenerate-log"
so that the Git commit message is generated from the ChangeLog for developers that manually
generate their ChangeLog using prepare-ChangeLog.

* Scripts/webkitpy/tool/commands/setupgitclone.py:
(SetupGitClone.execute):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@234770 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Tools/ChangeLog
Tools/Scripts/webkitpy/tool/commands/setupgitclone.py

index 58ad1d2..cf2a4a5 100644 (file)
@@ -1,3 +1,17 @@
+2018-08-10  Daniel Bates  <dabates@apple.com>
+
+        webkit-patch setup-git-clone should set Git core editor to commit-log-editor
+        https://bugs.webkit.org/show_bug.cgi?id=188473
+
+        Reviewed by Ryosuke Niwa.
+
+        Have "webkit-patch setup-git-clone" set the Git core editor to "perl Tools/Scripts/commit-log-editor --regenerate-log"
+        so that the Git commit message is generated from the ChangeLog for developers that manually
+        generate their ChangeLog using prepare-ChangeLog.
+
+        * Scripts/webkitpy/tool/commands/setupgitclone.py:
+        (SetupGitClone.execute):
+
 2018-08-10  Truitt Savell  <tsavell@apple.com>
 
         Unreviewed, rolling out r234749.
index 51f8e13..81bb498 100644 (file)
@@ -46,7 +46,7 @@ class SetupGitClone(Command):
 
         username, email = self._get_username_and_email(tool)
 
-        # FIXME: We shouldn't be using a privatd method
+        # FIXME: We shouldn't be using a private method.
         run_git = tool.scm()._run_git
         run_git(["pull"])
         run_git(["svn", "init", "--prefix=origin/", "-T", "trunk", "http://svn.webkit.org/repository/webkit"])
@@ -60,6 +60,8 @@ class SetupGitClone(Command):
         run_git(["config", "diff.objcpp.xfuncname", "^[-+@a-zA-Z_].*$"])
         run_git(["config", "diff.objcppheader.xfuncname", "^[@a-zA-Z_].*$"])
 
+        run_git(["config", "core.editor", "perl Tools/Scripts/commit-log-editor --regenerate-log"])
+
         if tool.user.confirm("Do you want to auto-color status, diff, and branch? (y/n)"):
             run_git(["config", "color.status", "auto"])
             run_git(["config", "color.diff", "auto"])