Skip to content

Commit

Permalink
get_maintainer.pl: teach git log to use --no-color
Browse files Browse the repository at this point in the history
When git has been set to always use color in .gitconfig then I get the
warning message

        Bad divisor in main::vcs_assign: 0

This is caused by vcs_file_signoffs not matching any commits due to the
pattern not understand the colour codes.  Fix this by telling git log to
never use colour.

Signed-off-by: Richard Kennedy <[email protected]>
Acked-by: Joe Perches <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Richard Kennedy authored and torvalds committed Feb 3, 2010
1 parent c85e9a9 commit 99cf611
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/get_maintainer.pl
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@
my %VCS_cmds_git = (
"execute_cmd" => \&git_execute_cmd,
"available" => '(which("git") ne "") && (-d ".git")',
"find_signers_cmd" => "git log --since=\$email_git_since -- \$file",
"find_commit_signers_cmd" => "git log -1 \$commit",
"find_signers_cmd" => "git log --no-color --since=\$email_git_since -- \$file",
"find_commit_signers_cmd" => "git log --no-color -1 \$commit",
"blame_range_cmd" => "git blame -l -L \$diff_start,+\$diff_length \$file",
"blame_file_cmd" => "git blame -l \$file",
"commit_pattern" => "^commit [0-9a-f]{40,40}",
Expand Down

0 comments on commit 99cf611

Please sign in to comment.