[Refactoring] In prepare-ChangeLog, replace $isGit and $isSVN with
authorharaken@chromium.org <haraken@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 15 Dec 2011 06:32:27 +0000 (06:32 +0000)
committerharaken@chromium.org <haraken@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 15 Dec 2011 06:32:27 +0000 (06:32 +0000)
commitc8b0ff7842406398118ad81c97bffb098234b99c
tree903d0c7231116b4662a25b4e88d802e191409b64
parent1add32d9b7bd250790c472fb42cd03f835774e41
[Refactoring] In prepare-ChangeLog, replace $isGit and $isSVN with
VCSUtils::isGit() and VCSUtils::isSVN().
https://bugs.webkit.org/show_bug.cgi?id=74485

Reviewed by David Kilzer.

We are planning to write unit-tests for prepare-ChangeLog in a run-leaks_unittest
manner. This bug is one of the incremental refactorings to remove all top-level
code and global variables from prepare-ChangeLog. This patch replaces $isGit and $isSVN
with VCSUtils::isGit() and VCSUtils::isSVN(). This patch also removes firstDirectoryOrCwd(),
assuming that no user will mix Git/SVN checkouts and thus we can judge SVN or Git
just by looking at the current working directory.

* Scripts/prepare-ChangeLog: Removed firstDirectoryOrCwd().
(diffFromToString):
(diffCommand):
(statusCommand):
(createPatchCommand):
(diffHeaderFormat):
(generateFileList):
(isAddedStatus):
(isConflictStatus):
(statusDescription):
(extractLineRange):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@102890 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Tools/ChangeLog
Tools/Scripts/prepare-ChangeLog