Skip to content
This repository was archived by the owner on Jul 19, 2025. It is now read-only.

Commit 43ec303

Browse files
author
dancostalis
committed
added support for changing the location of the .git root
1 parent 7e5951d commit 43ec303

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

lib/code_climate/test_reporter/configuration.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ def self.configuration
1919
end
2020

2121
class Configuration
22-
attr_accessor :branch, :logger, :profile, :path_prefix, :gzip_request
22+
attr_accessor :branch, :logger, :profile, :path_prefix, :gzip_request, :git_dir
2323

2424
def initialize
2525
@gzip_request = true

lib/code_climate/test_reporter/git.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ def git(command)
4949
end
5050

5151
def git_dir
52+
return CodeClimate::TestReporter.configuration.git_dir unless CodeClimate::TestReporter.configuration.git_dir.nil?
5253
defined?(Rails) ? Rails.root : '.'
5354
end
5455
end

0 commit comments

Comments
 (0)