circleci 0.0.3 → 0.0.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +160 -2
  3. data/lib/circleci.rb +14 -0
  4. metadata +191 -51
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a86544e6b9da3b2fa376f7275bcb52473c75cb86
4
- data.tar.gz: 998fb4f16e8048d70365f4e1787d13109af62b3b
3
+ metadata.gz: 3ff9c6775d04a8eff90cb6fd00dc57c93c928b65
4
+ data.tar.gz: 9f6c1dc808c57752a19dc38aa13d5fc9c7dd1c9a
5
5
  SHA512:
6
- metadata.gz: 3c3cd062804ccba7db22f20d1701afac2fca24090013e259ebc1784f01f84934ea016c09e43711d8b0614e9c59c65e65a1e995e8238651142a0bf250808960e7
7
- data.tar.gz: a4c8378365d0ced576c09791b40aeed55dac2904067311bc7c8ebb07ec96241495da6a0091a8aa190fb49f27d2292d7cdddc98952cd627c9353f010acff3d2ae
6
+ metadata.gz: 85165a924c57188cb13b2bdf1b670a88eaec784ffd012282ad2cd6ce569eebf9440626799273333b06f5c088d559fbf9e8fcaa216572a3f2e21b5296c2185ad5
7
+ data.tar.gz: 42dc404d38907f0ee4e5adcc32a990d9581ac593b55ea0472cd6ea011327c4c9eaa2c77160d57fdb15048d22c806ea2003e33cef46d12e5ee227a95d10abcec6
data/README.md CHANGED
@@ -106,7 +106,7 @@ Example response
106
106
  Build summary for each of the last 30 recent builds, ordered by build_num.
107
107
 
108
108
  ```ruby
109
- res = CirclCi::Project.recent_builds 'username', 'reponame'
109
+ res = CircleCi::Project.recent_builds 'username', 'reponame'
110
110
  res.success?
111
111
  res.body
112
112
  ```
@@ -145,7 +145,7 @@ Example response
145
145
  Build summary for each of the last 30 recent builds for a specific branch, ordered by build_num.
146
146
 
147
147
  ```ruby
148
- res = CirclCi::Project.recent_builds_branch 'username', 'reponame', 'branch'
148
+ res = CircleCi::Project.recent_builds_branch 'username', 'reponame', 'branch'
149
149
  res.success?
150
150
  res.body
151
151
  ```
@@ -324,6 +324,7 @@ Example response
324
324
  "build_num" : 22
325
325
  }
326
326
  ```
327
+
327
328
  #### CircleCi::Build.artifacts
328
329
 
329
330
  Artifacts produced by the build, returns an array of artifact details
@@ -351,6 +352,163 @@ res.body
351
352
  ]
352
353
  ```
353
354
 
355
+ #### CircleCi.organization
356
+
357
+ Recent builds for an entire organization
358
+
359
+ ```ruby
360
+ res = CircleCi.organization 'my-org'
361
+ res.succes?
362
+ res.body
363
+ ```
364
+
365
+ ```json
366
+ [
367
+ {
368
+ "dont_build":null,
369
+ "committer_name":"Chavez",
370
+ "usage_queued_at":"2014-04-12T10:29:59.352Z",
371
+ "branch":"master",
372
+ "body":"Update Missing ''e'' in CircleCi in README.md",
373
+ "author_date":"2014-03-12T23:14:53Z",
374
+ "node":[
375
+ {
376
+ "username":"ubuntu",
377
+ "ssh_enabled":null,
378
+ "port":64721,
379
+ "public_ip_addr":"54.82.224.94"
380
+ }
381
+ ],
382
+ "committer_date":"2014-03-12T23:14:53Z",
383
+ "compare":null,
384
+ "retries":null,
385
+ "parallel":1,
386
+ "committer_email":"mtchavez@users.noreply.github.com",
387
+ "build_time_millis":16308,
388
+ "why":"retry",
389
+ "author_email":"mtchavez@users.noreply.github.com",
390
+ "ssh_enabled":null,
391
+ "start_time":"2014-04-12T10:29:59.587Z",
392
+ "stop_time":"2014-04-12T10:30:15.895Z",
393
+ "lifecycle":"finished",
394
+ "user":{
395
+ "is_user":true,
396
+ "login":"hwartig",
397
+ "name":"Harald Wartig",
398
+ "email":"hwartig@users.noreply.github.com"
399
+ },
400
+ "subject":"Merge pull request #4 from Alex-Poon/master",
401
+ "messages":[
402
+
403
+ ],
404
+ "job_name":null,
405
+ "retry_of":1,
406
+ "previous_successful_build":{
407
+ "build_time_millis":37685,
408
+ "status":"success",
409
+ "build_num":1
410
+ },
411
+ "outcome":"success",
412
+ "status":"success",
413
+ "vcs_revision":"f33617404dc392ddd676fdde87cd5c87369e1857",
414
+ "build_num":2,
415
+ "username":"hwartigcom",
416
+ "vcs_url":"https://github.com/hwartigcom/circleci",
417
+ "timedout":false,
418
+ "previous":{
419
+ "build_time_millis":37685,
420
+ "status":"success",
421
+ "build_num":1
422
+ },
423
+ "canceled":false,
424
+ "infrastructure_fail":false,
425
+ "failed":null,
426
+ "reponame":"circleci",
427
+ "build_url":"https://circleci.com/gh/hwartigcom/circleci/2",
428
+ "feature_flags":{
429
+
430
+ },
431
+ "author_name":"Chavez",
432
+ "queued_at":"2014-04-12T10:29:59.517Z"
433
+ },
434
+ {
435
+ "dont_build":null,
436
+ "committer_name":"Chavez",
437
+ "usage_queued_at":"2014-04-08T06:58:09.522Z",
438
+ "branch":"master",
439
+ "body":"Update Missing ''e'' in CircleCi in README.md",
440
+ "author_date":"2014-03-12T23:14:53Z",
441
+ "node":[
442
+ {
443
+ "username":"ubuntu",
444
+ "ssh_enabled":null,
445
+ "port":64775,
446
+ "public_ip_addr":"54.198.9.232"
447
+ }
448
+ ],
449
+ "committer_date":"2014-03-12T23:14:53Z",
450
+ "compare":null,
451
+ "retries":[
452
+ 2
453
+ ],
454
+ "parallel":1,
455
+ "committer_email":"mtchavez@users.noreply.github.com",
456
+ "build_time_millis":37685,
457
+ "why":"first-build",
458
+ "author_email":"mtchavez@users.noreply.github.com",
459
+ "ssh_enabled":null,
460
+ "start_time":"2014-04-08T06:58:09.868Z",
461
+ "stop_time":"2014-04-08T06:58:47.553Z",
462
+ "lifecycle":"finished",
463
+ "user":{
464
+ "is_user":true,
465
+ "login":"hwartig",
466
+ "name":"Harald Wartig",
467
+ "email":"hwartig@users.noreply.github.com"
468
+ },
469
+ "subject":"Merge pull request #4 from Alex-Poon/master",
470
+ "messages":[
471
+
472
+ ],
473
+ "job_name":null,
474
+ "retry_of":null,
475
+ "previous_successful_build":null,
476
+ "outcome":"success",
477
+ "status":"success",
478
+ "vcs_revision":"f33617404dc392ddd676fdde87cd5c87369e1857",
479
+ "build_num":1,
480
+ "username":"hwartigcom",
481
+ "vcs_url":"https://github.com/hwartigcom/circleci",
482
+ "timedout":false,
483
+ "previous":null,
484
+ "all_commit_details":[
485
+ {
486
+ "committer_name":"Chavez",
487
+ "body":"Update Missing ''e'' in CircleCi in README.md",
488
+ "author_date":"2014-03-12T23:14:53Z",
489
+ "committer_date":"2014-03-12T23:14:53Z",
490
+ "commit_url":"https://github.com/hwartigcom/circleci/commit/f33617404dc392ddd676fdde87cd5c87369e1857",
491
+ "committer_email":"mtchavez@users.noreply.github.com",
492
+ "author_email":"mtchavez@users.noreply.github.com",
493
+ "subject":"Merge pull request #4 from Alex-Poon/master",
494
+ "commit":"f33617404dc392ddd676fdde87cd5c87369e1857",
495
+ "author_name":"Chavez"
496
+ }
497
+ ],
498
+ "canceled":false,
499
+ "infrastructure_fail":false,
500
+ "failed":null,
501
+ "reponame":"circleci",
502
+ "build_url":"https://circleci.com/gh/hwartigcom/circleci/1",
503
+ "feature_flags":{
504
+
505
+ },
506
+ "author_name":"Chavez",
507
+ "queued_at":"2014-04-08T06:58:09.739Z"
508
+ }
509
+ ]
510
+ ```
511
+
354
512
  ### Tests
355
513
 
356
514
  Run using ```rake```
data/lib/circleci.rb CHANGED
@@ -41,4 +41,18 @@ module CircleCi
41
41
  Http.new(config)
42
42
  end
43
43
 
44
+ ##
45
+ #
46
+ # Get recent builds for an organization
47
+ #
48
+ # @param name [String] Name of the organization. Currently CircleCi treats
49
+ # the name case sensetive so make sure the spelling is the same
50
+ # as the github organisation.
51
+ # @param params [Hash] Additional query params.
52
+ # @return [CircleCi::Response] - Response object.
53
+
54
+ def organization(name, params = {})
55
+ http.get "/organization/#{name}", params
56
+ end
57
+
44
58
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: circleci
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chavez
@@ -10,126 +10,266 @@ bindir: bin
10
10
  cert_chain: []
11
11
  date: 2014-01-29 00:00:00.000000000 Z
12
12
  dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: hashie
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: 2.1.0
20
+ - - ">="
21
+ - !ruby/object:Gem::Version
22
+ version: 2.1.0
23
+ type: :runtime
24
+ prerelease: false
25
+ version_requirements: !ruby/object:Gem::Requirement
26
+ requirements:
27
+ - - "~>"
28
+ - !ruby/object:Gem::Version
29
+ version: 2.1.0
30
+ - - ">="
31
+ - !ruby/object:Gem::Version
32
+ version: 2.1.0
13
33
  - !ruby/object:Gem::Dependency
14
34
  name: rest-client
15
35
  requirement: !ruby/object:Gem::Requirement
16
36
  requirements:
17
- - - ~>
37
+ - - "~>"
18
38
  - !ruby/object:Gem::Version
19
39
  version: 1.6.7
20
- - - '>='
40
+ - - ">="
21
41
  - !ruby/object:Gem::Version
22
42
  version: 1.6.7
23
43
  type: :runtime
24
44
  prerelease: false
25
45
  version_requirements: !ruby/object:Gem::Requirement
26
46
  requirements:
27
- - - ~>
47
+ - - "~>"
28
48
  - !ruby/object:Gem::Version
29
49
  version: 1.6.7
30
- - - '>='
50
+ - - ">="
31
51
  - !ruby/object:Gem::Version
32
52
  version: 1.6.7
33
53
  - !ruby/object:Gem::Dependency
34
- name: hashie
54
+ name: dotenv
35
55
  requirement: !ruby/object:Gem::Requirement
36
56
  requirements:
37
- - - ~>
57
+ - - "~>"
38
58
  - !ruby/object:Gem::Version
39
- version: 1.2.0
40
- - - '>='
59
+ version: 0.10.0
60
+ - - ">="
41
61
  - !ruby/object:Gem::Version
42
- version: 1.2.0
43
- type: :runtime
62
+ version: 0.10.0
63
+ type: :development
44
64
  prerelease: false
45
65
  version_requirements: !ruby/object:Gem::Requirement
46
66
  requirements:
47
- - - ~>
67
+ - - "~>"
48
68
  - !ruby/object:Gem::Version
49
- version: 1.2.0
50
- - - '>='
69
+ version: 0.10.0
70
+ - - ">="
51
71
  - !ruby/object:Gem::Version
52
- version: 1.2.0
72
+ version: 0.10.0
73
+ - !ruby/object:Gem::Dependency
74
+ name: gemcutter
75
+ requirement: !ruby/object:Gem::Requirement
76
+ requirements:
77
+ - - "~>"
78
+ - !ruby/object:Gem::Version
79
+ version: 0.7.1
80
+ - - ">="
81
+ - !ruby/object:Gem::Version
82
+ version: 0.7.1
83
+ type: :development
84
+ prerelease: false
85
+ version_requirements: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - "~>"
88
+ - !ruby/object:Gem::Version
89
+ version: 0.7.1
90
+ - - ">="
91
+ - !ruby/object:Gem::Version
92
+ version: 0.7.1
93
+ - !ruby/object:Gem::Dependency
94
+ name: pry
95
+ requirement: !ruby/object:Gem::Requirement
96
+ requirements:
97
+ - - "~>"
98
+ - !ruby/object:Gem::Version
99
+ version: 0.9.12
100
+ - - ">="
101
+ - !ruby/object:Gem::Version
102
+ version: 0.9.12.6
103
+ type: :development
104
+ prerelease: false
105
+ version_requirements: !ruby/object:Gem::Requirement
106
+ requirements:
107
+ - - "~>"
108
+ - !ruby/object:Gem::Version
109
+ version: 0.9.12
110
+ - - ">="
111
+ - !ruby/object:Gem::Version
112
+ version: 0.9.12.6
113
+ - !ruby/object:Gem::Dependency
114
+ name: rake
115
+ requirement: !ruby/object:Gem::Requirement
116
+ requirements:
117
+ - - "~>"
118
+ - !ruby/object:Gem::Version
119
+ version: 10.1.0
120
+ - - ">="
121
+ - !ruby/object:Gem::Version
122
+ version: 10.1.0
123
+ type: :development
124
+ prerelease: false
125
+ version_requirements: !ruby/object:Gem::Requirement
126
+ requirements:
127
+ - - "~>"
128
+ - !ruby/object:Gem::Version
129
+ version: 10.1.0
130
+ - - ">="
131
+ - !ruby/object:Gem::Version
132
+ version: 10.1.0
133
+ - !ruby/object:Gem::Dependency
134
+ name: redcarpet
135
+ requirement: !ruby/object:Gem::Requirement
136
+ requirements:
137
+ - - "~>"
138
+ - !ruby/object:Gem::Version
139
+ version: 3.1.0
140
+ - - ">="
141
+ - !ruby/object:Gem::Version
142
+ version: 3.1.0
143
+ type: :development
144
+ prerelease: false
145
+ version_requirements: !ruby/object:Gem::Requirement
146
+ requirements:
147
+ - - "~>"
148
+ - !ruby/object:Gem::Version
149
+ version: 3.1.0
150
+ - - ">="
151
+ - !ruby/object:Gem::Version
152
+ version: 3.1.0
53
153
  - !ruby/object:Gem::Dependency
54
154
  name: rspec
55
155
  requirement: !ruby/object:Gem::Requirement
56
156
  requirements:
57
- - - ~>
157
+ - - "~>"
58
158
  - !ruby/object:Gem::Version
59
- version: '2.0'
60
- - - '>='
159
+ version: 2.14.1
160
+ - - ">="
61
161
  - !ruby/object:Gem::Version
62
- version: '2.0'
162
+ version: 2.14.1
63
163
  type: :development
64
164
  prerelease: false
65
165
  version_requirements: !ruby/object:Gem::Requirement
66
166
  requirements:
67
- - - ~>
167
+ - - "~>"
68
168
  - !ruby/object:Gem::Version
69
- version: '2.0'
70
- - - '>='
169
+ version: 2.14.1
170
+ - - ">="
71
171
  - !ruby/object:Gem::Version
72
- version: '2.0'
172
+ version: 2.14.1
73
173
  - !ruby/object:Gem::Dependency
74
174
  name: simplecov
75
175
  requirement: !ruby/object:Gem::Requirement
76
176
  requirements:
77
- - - ~>
177
+ - - "~>"
78
178
  - !ruby/object:Gem::Version
79
- version: 0.7.1
80
- - - '>='
179
+ version: 0.8.2
180
+ - - ">="
81
181
  - !ruby/object:Gem::Version
82
- version: 0.7.1
182
+ version: 0.8.2
83
183
  type: :development
84
184
  prerelease: false
85
185
  version_requirements: !ruby/object:Gem::Requirement
86
186
  requirements:
87
- - - ~>
187
+ - - "~>"
88
188
  - !ruby/object:Gem::Version
89
- version: 0.7.1
90
- - - '>='
189
+ version: 0.8.2
190
+ - - ">="
91
191
  - !ruby/object:Gem::Version
92
- version: 0.7.1
192
+ version: 0.8.2
193
+ - !ruby/object:Gem::Dependency
194
+ name: typhoeus
195
+ requirement: !ruby/object:Gem::Requirement
196
+ requirements:
197
+ - - "~>"
198
+ - !ruby/object:Gem::Version
199
+ version: 0.6.8
200
+ - - ">="
201
+ - !ruby/object:Gem::Version
202
+ version: 0.6.8
203
+ type: :development
204
+ prerelease: false
205
+ version_requirements: !ruby/object:Gem::Requirement
206
+ requirements:
207
+ - - "~>"
208
+ - !ruby/object:Gem::Version
209
+ version: 0.6.8
210
+ - - ">="
211
+ - !ruby/object:Gem::Version
212
+ version: 0.6.8
93
213
  - !ruby/object:Gem::Dependency
94
214
  name: vcr
95
215
  requirement: !ruby/object:Gem::Requirement
96
216
  requirements:
97
- - - ~>
217
+ - - "~>"
98
218
  - !ruby/object:Gem::Version
99
- version: 2.2.5
100
- - - '>='
219
+ version: 2.9.0
220
+ - - ">="
101
221
  - !ruby/object:Gem::Version
102
- version: 2.2.5
222
+ version: 2.9.0
103
223
  type: :development
104
224
  prerelease: false
105
225
  version_requirements: !ruby/object:Gem::Requirement
106
226
  requirements:
107
- - - ~>
227
+ - - "~>"
108
228
  - !ruby/object:Gem::Version
109
- version: 2.2.5
110
- - - '>='
229
+ version: 2.9.0
230
+ - - ">="
111
231
  - !ruby/object:Gem::Version
112
- version: 2.2.5
232
+ version: 2.9.0
113
233
  - !ruby/object:Gem::Dependency
114
234
  name: webmock
115
235
  requirement: !ruby/object:Gem::Requirement
116
236
  requirements:
117
- - - ~>
237
+ - - "~>"
238
+ - !ruby/object:Gem::Version
239
+ version: 1.17.4
240
+ - - ">="
241
+ - !ruby/object:Gem::Version
242
+ version: 1.17.4
243
+ type: :development
244
+ prerelease: false
245
+ version_requirements: !ruby/object:Gem::Requirement
246
+ requirements:
247
+ - - "~>"
248
+ - !ruby/object:Gem::Version
249
+ version: 1.17.4
250
+ - - ">="
251
+ - !ruby/object:Gem::Version
252
+ version: 1.17.4
253
+ - !ruby/object:Gem::Dependency
254
+ name: yard
255
+ requirement: !ruby/object:Gem::Requirement
256
+ requirements:
257
+ - - "~>"
118
258
  - !ruby/object:Gem::Version
119
- version: 1.8.11
120
- - - '>='
259
+ version: 0.8.7
260
+ - - ">="
121
261
  - !ruby/object:Gem::Version
122
- version: 1.8.11
262
+ version: 0.8.7.4
123
263
  type: :development
124
264
  prerelease: false
125
265
  version_requirements: !ruby/object:Gem::Requirement
126
266
  requirements:
127
- - - ~>
267
+ - - "~>"
128
268
  - !ruby/object:Gem::Version
129
- version: 1.8.11
130
- - - '>='
269
+ version: 0.8.7
270
+ - - ">="
131
271
  - !ruby/object:Gem::Version
132
- version: 1.8.11
272
+ version: 0.8.7.4
133
273
  description: Wraps Circle CI API calls in a gem.
134
274
  email: nailsbrokeandfell@gmail.com
135
275
  executables: []
@@ -152,22 +292,22 @@ licenses:
152
292
  metadata: {}
153
293
  post_install_message:
154
294
  rdoc_options:
155
- - --charset=UTF-8 --main=README.md
295
+ - "--charset=UTF-8 --main=README.md"
156
296
  require_paths:
157
297
  - lib
158
298
  required_ruby_version: !ruby/object:Gem::Requirement
159
299
  requirements:
160
- - - '>='
300
+ - - ">="
161
301
  - !ruby/object:Gem::Version
162
302
  version: '0'
163
303
  required_rubygems_version: !ruby/object:Gem::Requirement
164
304
  requirements:
165
- - - '>='
305
+ - - ">="
166
306
  - !ruby/object:Gem::Version
167
307
  version: '0'
168
308
  requirements: []
169
309
  rubyforge_project:
170
- rubygems_version: 2.2.1
310
+ rubygems_version: 2.2.2
171
311
  signing_key:
172
312
  specification_version: 4
173
313
  summary: Circle CI API Wrapper