git-semaphore 2.6.0 → 2.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/exe/git-semaphore +9 -1
- data/lib/git/semaphore/project.rb +0 -5
- data/lib/git/semaphore/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: 9fed232a9fd1e8a29fd1083e1161f37ea77ea91f
|
4
|
+
data.tar.gz: 3044494fe8a2e01cf45fafc319c57e2100b83e08
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 16c8f3e9f5086d92a9eadb34b1b6d723ea52465fbcaec99f17c2d6e18c644ead5cbeee143908b19ce45484cf5e2c0beb4e773c00999fc7d19551e19e54775673
|
7
|
+
data.tar.gz: e7a7f8b6a74ccdf3c7959db150cb0d7a7ee521f7dea3145c6b19baa4fccbbda75cd5b5ddaa2a09e653fe8457349dd49f8961cc0f8755344e0c68a879daed79f9
|
data/exe/git-semaphore
CHANGED
@@ -64,6 +64,14 @@ class SafeProject
|
|
64
64
|
@project = project
|
65
65
|
end
|
66
66
|
|
67
|
+
def result
|
68
|
+
return unless @project.exist?
|
69
|
+
|
70
|
+
@project.branches(true) # refresh
|
71
|
+
status = @project.status(true) # refresh
|
72
|
+
status.fetch('result', nil)
|
73
|
+
end
|
74
|
+
|
67
75
|
def method_missing(name, *args, &block)
|
68
76
|
if @project.exist?
|
69
77
|
@project.send(name, *args, &block)
|
@@ -88,7 +96,7 @@ when options.projects? then puts Git::Semaphore::Project.all(refresh).to_json
|
|
88
96
|
|
89
97
|
when options.browse? then puts project.browse.to_json
|
90
98
|
when options.rebuild? then puts project.rebuild.to_json
|
91
|
-
when options.result? then
|
99
|
+
when options.result? then (result = project.result) && puts(result)
|
92
100
|
|
93
101
|
when options.settings? then puts project.settings.to_json
|
94
102
|
when options.internals? then puts project.internals.to_json
|
@@ -141,11 +141,6 @@ module Git
|
|
141
141
|
Git::Semaphore::API.rebuild(project_hash_id, branch_id, @auth_token)
|
142
142
|
end
|
143
143
|
|
144
|
-
def result
|
145
|
-
Git::Semaphore::API.status(project_hash_id, branch_id, @auth_token)\
|
146
|
-
['result'] # the latest un-cached build result for the current branch
|
147
|
-
end
|
148
|
-
|
149
144
|
def browse
|
150
145
|
`open #{branch_url}`
|
151
146
|
{ url: branch_url }
|