Browse files

Merge pull request #18 from brantb/master

git-wtf: Change delimiter of `git log --pretty` format string to |.
  • Loading branch information...
2 parents 0d3a497 + d871383 commit 14879c9e058bea3f29f0088b3dd1b6946c8846c8 @ddollar committed Jun 18, 2012
Showing with 4 additions and 4 deletions.
  1. +4 −4 git-wtf
View
8 git-wtf
@@ -65,13 +65,13 @@ def run_command(command)
end
def commits_between from, to
- commits = run_command(%{ git log --pretty=format:"%h-%ae-%s" #{from}..#{to} }).split(/[\r\n]+/).map do |raw_commit|
- raw_commit_parts = raw_commit.split('-')
+ commits = run_command(%{ git log --pretty=format:"%h|%ae|%s" #{from}..#{to} }).split(/[\r\n]+/).map do |raw_commit|
+ raw_commit_parts = raw_commit.split('|')
{
:hash => raw_commit_parts.shift,
:author => raw_commit_parts.shift.split('@').first,
- :message => raw_commit_parts.join('-')
+ :message => raw_commit_parts.join('|')
}
end
@@ -207,4 +207,4 @@ if repo[:features].length > 0
repo[:features].each do |branch|
branch_sync_status(repo[:current], branch, false, true, "#{branch[:name]} is merged in", "#{branch[:name]} needs to be merged in")
end
-end
+end

0 comments on commit 14879c9

Please sign in to comment.