Sha256: 330c7c6c6c85a170b1346d7e52ea0c801b01c85966fcd5e25add0e9faf18a3ba

Contents?: true

Size: 280 Bytes

Versions: 4

Compression:

Stored size: 280 Bytes

Contents

# -*- encoding : utf-8 -*-
module GitStats
  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
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
git_stats-1.0.17 lib/git_stats/command_runner.rb
git_stats-1.0.16 lib/git_stats/command_runner.rb
git_stats-1.0.15 lib/git_stats/command_runner.rb
git_stats-1.0.14 lib/git_stats/command_runner.rb