mirror of
https://github.com/tomgi/git_stats.git
synced 2024-12-22 13:32:17 +01:00
fixed encoding problem with some repositories
This commit is contained in:
parent
a801a2f02b
commit
116cc5a8f4
1 changed files with 5 additions and 0 deletions
|
@ -3,6 +3,11 @@ module GitStats
|
|||
module GitData
|
||||
class CommandRunner
|
||||
def run(path, command)
|
||||
execute(command, path).encode!('UTF-8', 'UTF-8', :invalid => :replace)
|
||||
end
|
||||
|
||||
private
|
||||
def execute(command, path)
|
||||
Dir.chdir(path) { %x[#{command}] }
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue