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

Commit 0de6eda

Browse files
committed
Merge pull request #53 from deivid-rodriguez/add_appveyor_support
Add appveyor support
2 parents 28b6f79 + a27b345 commit 0de6eda

File tree

3 files changed

+11
-2
lines changed

3 files changed

+11
-2
lines changed

lib/code_climate/test_reporter/ci.rb

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,15 @@ def self.service_data(env = ENV)
4545
branch: env['WERCKER_GIT_BRANCH'],
4646
commit_sha: env['WERCKER_GIT_COMMIT']
4747
}
48+
elsif env['APPVEYOR']
49+
{
50+
name: "appveyor",
51+
build_identifier: env['APPVEYOR_BUILD_ID'],
52+
build_url: env['APPVEYOR_API_URL'],
53+
branch: env['APPVEYOR_REPO_BRANCH'],
54+
commit_sha: env['APPVEYOR_REPO_COMMIT'],
55+
pull_request: env['APPVEYOR_PULL_REQUEST_NUMBER']
56+
}
4857
elsif env['CI_NAME'] =~ /DRONE/i
4958
{
5059
name: "drone",

lib/code_climate/test_reporter/git.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def clean_git_branch
3232
private
3333

3434
def committed_at
35-
committed_at = `git log -1 --pretty=format:'%ct'`
35+
committed_at = `git log -1 --pretty=format:%ct`
3636
committed_at.to_i.zero? ? nil : committed_at.to_i
3737
end
3838

spec/lib/git_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ module CodeClimate::TestReporter
66
it 'returns a hash with git information.' do
77
expected_git_hash = {
88
head: `git log -1 --pretty=format:'%H'`,
9-
committed_at: `git log -1 --pretty=format:'%ct'`.to_i,
9+
committed_at: `git log -1 --pretty=format:%ct`.to_i,
1010
branch: Git.send(:branch_from_git)
1111
}
1212

0 commit comments

Comments
 (0)