inch_ci-worker 0.3.0.rc12 → 0.3.0.rc13
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/inch_ci/worker/build_json.rb +8 -8
- data/lib/inch_ci/worker/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3105a8a4a110164970a664f1851855d69a357cac
|
4
|
+
data.tar.gz: 8adcd7168b8d15990fef3609637c2a50ad6f5cea
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 309c08282291e6a08b4ba17352fcf2ddb467f621a4af77ea0eb9297bf920fbd75db60b44f2e1394649dde524a18486ba2c76c71a12a2df3e4aa9fe71beae4fd9
|
7
|
+
data.tar.gz: 06bb1a6f7290c1dd83af4b95fcf8ca5bf25032bc79eaa8c062e4daec7b6b2a5890a0a313b5725e1e6274a6e15111e920efc6748461e9bb40c27133424a1ac682
|
@@ -11,20 +11,20 @@ module InchCI
|
|
11
11
|
attr_reader :language, :branch_name, :revision, :nwo, :url
|
12
12
|
|
13
13
|
def initialize(filename)
|
14
|
-
json = JSON[File.read(filename)]
|
15
|
-
@language = json['language']
|
16
|
-
@branch_name = json['branch_name'] || json['travis_branch']
|
17
|
-
@revision = json['revision'] || json['travis_commit']
|
18
|
-
@nwo = json['nwo'] || json['travis_repo_slug']
|
19
|
-
@url = json['git_repo_url']
|
14
|
+
@json = JSON[File.read(filename)]
|
15
|
+
@language = @json['language']
|
16
|
+
@branch_name = @json['branch_name'] || @json['travis_branch']
|
17
|
+
@revision = @json['revision'] || @json['travis_commit']
|
18
|
+
@nwo = @json['nwo'] || @json['travis_repo_slug']
|
19
|
+
@url = @json['git_repo_url']
|
20
20
|
end
|
21
21
|
|
22
22
|
def travis?
|
23
|
-
|
23
|
+
!@json['travis'].nil?
|
24
24
|
end
|
25
25
|
|
26
26
|
def to_h(include_objects: true)
|
27
|
-
h = json.dup
|
27
|
+
h = @json.dup
|
28
28
|
h.delete('objects') unless include_objects
|
29
29
|
h
|
30
30
|
end
|