buildkit 1.5.0 → 1.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yml +1 -1
- data/.github/workflows/cla.yml +22 -0
- data/.rubocop.yml +0 -3
- data/.ruby-version +1 -0
- data/buildkit.gemspec +1 -1
- data/dev.yml +1 -1
- data/lib/buildkit/client/pipelines.rb +12 -0
- data/lib/buildkit/client.rb +2 -1
- data/lib/buildkit/version.rb +1 -1
- metadata +6 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0e7e69a2ddeff1b7bb80376140cdaa6ab806ae4d9d00eab6ed18125dad032fc2
|
4
|
+
data.tar.gz: b9455cdb046ebf0c351f8cedca064a65d3a0e5a729ebe29e2dd845fc6a522944
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3f7ca278659b24de9d55aac4b78daec828a73ee198eb2df1feba25e67e7b4cb8c253be04934359f1e1abdc1c8d50cbba189a6d4e81588b5e95ca0b2ae69b407e
|
7
|
+
data.tar.gz: 00ee40a520605b816792a7a8365a5bd8e2010896e219da8c86d62ca344fdcd750a26a38dd81a4e70883181563ee27908343d21e563bc8cbef4e9b5169f676581
|
data/.github/workflows/ci.yml
CHANGED
@@ -0,0 +1,22 @@
|
|
1
|
+
name: Contributor License Agreement (CLA)
|
2
|
+
|
3
|
+
on:
|
4
|
+
pull_request_target:
|
5
|
+
types: [opened, synchronize]
|
6
|
+
issue_comment:
|
7
|
+
types: [created]
|
8
|
+
|
9
|
+
jobs:
|
10
|
+
cla:
|
11
|
+
runs-on: ubuntu-latest
|
12
|
+
if: |
|
13
|
+
(github.event.issue.pull_request
|
14
|
+
&& !github.event.issue.pull_request.merged_at
|
15
|
+
&& contains(github.event.comment.body, 'signed')
|
16
|
+
)
|
17
|
+
|| (github.event.pull_request && !github.event.pull_request.merged)
|
18
|
+
steps:
|
19
|
+
- uses: Shopify/shopify-cla-action@v1
|
20
|
+
with:
|
21
|
+
github-token: ${{ secrets.GITHUB_TOKEN }}
|
22
|
+
cla-token: ${{ secrets.CLA_TOKEN }}
|
data/.rubocop.yml
CHANGED
data/.ruby-version
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
2.5.5
|
data/buildkit.gemspec
CHANGED
@@ -21,7 +21,7 @@ Gem::Specification.new do |spec|
|
|
21
21
|
|
22
22
|
spec.metadata['allowed_push_host'] = 'https://rubygems.org'
|
23
23
|
|
24
|
-
spec.required_ruby_version = '>= 2.
|
24
|
+
spec.required_ruby_version = '>= 2.5'
|
25
25
|
|
26
26
|
spec.add_dependency 'sawyer', '>= 0.6'
|
27
27
|
spec.add_development_dependency 'bundler'
|
data/dev.yml
CHANGED
@@ -91,6 +91,18 @@ module Buildkit
|
|
91
91
|
def unarchive_pipeline(org, pipeline)
|
92
92
|
post("/v2/organizations/#{org}/pipelines/#{pipeline}/unarchive")
|
93
93
|
end
|
94
|
+
|
95
|
+
# Delete a pipeline
|
96
|
+
#
|
97
|
+
# @param org [String] Organization slug.
|
98
|
+
# @param pipeline [String] pipeline slug.
|
99
|
+
# @see https://buildkite.com/docs/apis/rest-api/pipelines#delete-a-pipeline
|
100
|
+
# @example
|
101
|
+
# Buildkit.delete_pipeline('my-great-org', 'great-pipeline')
|
102
|
+
#
|
103
|
+
def delete_pipeline(org, pipeline)
|
104
|
+
delete("/v2/organizations/#{org}/pipelines/#{pipeline}")
|
105
|
+
end
|
94
106
|
end
|
95
107
|
end
|
96
108
|
end
|
data/lib/buildkit/client.rb
CHANGED
@@ -148,6 +148,7 @@ module Buildkit
|
|
148
148
|
response.concat @last_response.data
|
149
149
|
|
150
150
|
break if @last_response.headers[:link].nil?
|
151
|
+
|
151
152
|
link_header = parse_link_header(@last_response.headers[:link])
|
152
153
|
break if link_header[:next].nil?
|
153
154
|
|
@@ -170,7 +171,7 @@ module Buildkit
|
|
170
171
|
http.headers[:accept] = 'application/json'
|
171
172
|
http.headers[:content_type] = 'application/json'
|
172
173
|
http.headers[:user_agent] = "Buildkit v#{Buildkit::VERSION}"
|
173
|
-
if Gem::Version.new(Faraday::VERSION) >= Gem::Version.new(
|
174
|
+
if Gem::Version.new(Faraday::VERSION) >= Gem::Version.new('1.7.1')
|
174
175
|
http.request :authorization, 'Bearer', @token
|
175
176
|
else
|
176
177
|
http.authorization 'Bearer', @token
|
data/lib/buildkit/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: buildkit
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jean Boussier
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-04-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: sawyer
|
@@ -46,10 +46,12 @@ extensions: []
|
|
46
46
|
extra_rdoc_files: []
|
47
47
|
files:
|
48
48
|
- ".github/workflows/ci.yml"
|
49
|
+
- ".github/workflows/cla.yml"
|
49
50
|
- ".gitignore"
|
50
51
|
- ".rspec"
|
51
52
|
- ".rubocop.yml"
|
52
53
|
- ".rubocop_todo.yml"
|
54
|
+
- ".ruby-version"
|
53
55
|
- Gemfile
|
54
56
|
- LICENSE.txt
|
55
57
|
- README.md
|
@@ -83,14 +85,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
83
85
|
requirements:
|
84
86
|
- - ">="
|
85
87
|
- !ruby/object:Gem::Version
|
86
|
-
version: '2.
|
88
|
+
version: '2.5'
|
87
89
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
88
90
|
requirements:
|
89
91
|
- - ">="
|
90
92
|
- !ruby/object:Gem::Version
|
91
93
|
version: '0'
|
92
94
|
requirements: []
|
93
|
-
rubygems_version: 3.
|
95
|
+
rubygems_version: 3.5.7
|
94
96
|
signing_key:
|
95
97
|
specification_version: 4
|
96
98
|
summary: Ruby toolkit for working with the Buildkite API
|