Skip to content

Commit

Permalink
dev-vcs/gitstats: force text processing by grep
Browse files Browse the repository at this point in the history
Fix for bug 575946 by forcing grep to process commit data as text even when
invalid unicode characters appear.

Reported-by: Martin Mokrejš

Package-Manager: portage-2.2.28
  • Loading branch information
amadio committed Apr 1, 2016
1 parent 023d4cd commit 93db43b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
--- a/gitstats 2016-04-01 09:46:31.000000000 -0300
+++ b/gitstats 2016-04-01 09:46:18.458667610 -0300
@@ -327,7 +327,7 @@

# Collect revision statistics
# Outputs "<stamp> <date> <time> <timezone> <author> '<' <mail> '>'"
- lines = getpipeoutput(['git rev-list --pretty=format:"%%at %%ai %%aN <%%aE>" %s' % getlogrange('HEAD'), 'grep -v ^commit']).split('\n')
+ lines = getpipeoutput(['git rev-list --pretty=format:"%%at %%ai %%aN <%%aE>" %s' % getlogrange('HEAD'), 'grep -av ^commit']).split('\n')
for line in lines:
parts = line.split(' ', 4)
author = ''
1 change: 1 addition & 0 deletions dev-vcs/gitstats/gitstats-0_pre20151223.ebuild
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ src_prepare() {
sed \
-e "s:basedirs = \[binarypath, secondarypath, '/usr/share/gitstats'\]:basedirs = \['${EPREFIX}/usr/share/gitstats'\]:g" \
-i gitstats || die "failed to fix static files path"
eapply "${FILESDIR}"/${P}-grep-force-text.patch
default
}

Expand Down

0 comments on commit 93db43b

Please sign in to comment.