buildkite-builder 1.0.0.beta.1 → 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/VERSION +1 -0
- data/bin/buildkite-builder +1 -1
- data/exe/buildkite-builder +6 -0
- data/lib/buildkite/builder.rb +0 -3
- data/lib/buildkite/builder/commands.rb +1 -0
- data/lib/buildkite/builder/commands/run.rb +17 -0
- data/lib/buildkite/builder/runner.rb +1 -0
- data/lib/buildkite/pipelines/helpers/soft_fail.rb +17 -0
- metadata +12 -15
- data/.gitignore +0 -11
- data/.rspec +0 -3
- data/CODE_OF_CONDUCT.md +0 -74
- data/Gemfile +0 -13
- data/Gemfile.lock +0 -56
- data/Rakefile +0 -6
- data/buildkite-builder.gemspec +0 -28
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 99dafa9c69892d614803f254d86690b24cdca47b5c8d5e6355abfe29180df5e2
|
4
|
+
data.tar.gz: 35e7a93c70449afa735b1ebde2979ecc63e51c8e549031674258083bcaa273f4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dd431d4a2db144be98214266408f4b6bbaf76ea354347b559fe78149f6225a1ab372b4aa3fe62b38ed1ce7eaf9204a68e81cd37c629d0698e28eaedcf2c0ff2c
|
7
|
+
data.tar.gz: 4c57e2a787c47c77f68582690530ea232f14516256d54e8fb5ede6a3600fa6b83425fb1a5012a687d4caa9c2f12ee03350ba4227f55646cf169118d829775cd2
|
data/VERSION
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
1.0.0
|
data/bin/buildkite-builder
CHANGED
data/lib/buildkite/builder.rb
CHANGED
@@ -1,13 +1,10 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
require 'bundler'
|
4
|
-
require 'logger'
|
5
4
|
require 'pathname'
|
6
5
|
|
7
6
|
module Buildkite
|
8
7
|
module Builder
|
9
|
-
VERSION = '1.0.0.beta.1'
|
10
|
-
|
11
8
|
autoload :Commands, File.expand_path('builder/commands', __dir__)
|
12
9
|
autoload :Definition, File.expand_path('builder/definition', __dir__)
|
13
10
|
autoload :FileResolver, File.expand_path('builder/file_resolver', __dir__)
|
@@ -0,0 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Buildkite
|
4
|
+
module Builder
|
5
|
+
module Commands
|
6
|
+
class Run < Abstract
|
7
|
+
private
|
8
|
+
|
9
|
+
self.description = 'Builds and uploads the generated pipeline.'
|
10
|
+
|
11
|
+
def run
|
12
|
+
Builder::Runner.run
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
@@ -4,6 +4,23 @@ module Buildkite
|
|
4
4
|
module Pipelines
|
5
5
|
module Helpers
|
6
6
|
module SoftFail
|
7
|
+
def soft_fail(*value)
|
8
|
+
# soft_fail can be an array of exit_statuses or true
|
9
|
+
# https://buildkite.com/docs/pipelines/command-step#soft-fail-attributes
|
10
|
+
|
11
|
+
if value.first == true
|
12
|
+
current = get('soft_fail')
|
13
|
+
|
14
|
+
if current.is_a?(Array)
|
15
|
+
raise ArgumentError, "Cannot set soft_fail to true when it's already an array.\nsoft_fail: #{current}"
|
16
|
+
else
|
17
|
+
set('soft_fail', true)
|
18
|
+
end
|
19
|
+
else
|
20
|
+
super
|
21
|
+
end
|
22
|
+
end
|
23
|
+
|
7
24
|
def soft_fail_on_status(*statuses)
|
8
25
|
statuses.each do |status|
|
9
26
|
soft_fail(exit_status: status)
|
metadata
CHANGED
@@ -1,17 +1,18 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: buildkite-builder
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.0
|
4
|
+
version: 1.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ngan Pham
|
8
8
|
- Andrew Lee
|
9
9
|
autorequire:
|
10
|
-
bindir:
|
10
|
+
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date: 2020-
|
12
|
+
date: 2020-12-01 00:00:00.000000000 Z
|
13
13
|
dependencies: []
|
14
|
-
description:
|
14
|
+
description: Buildkite Builder is a tool that provides projects using Buildkite to
|
15
|
+
have dynamic pipeline functionality.
|
15
16
|
email:
|
16
17
|
- gusto-opensource-buildkite@gusto.com
|
17
18
|
executables:
|
@@ -19,25 +20,21 @@ executables:
|
|
19
20
|
extensions: []
|
20
21
|
extra_rdoc_files: []
|
21
22
|
files:
|
22
|
-
- ".gitignore"
|
23
|
-
- ".rspec"
|
24
23
|
- CHANGELOG.md
|
25
|
-
- CODE_OF_CONDUCT.md
|
26
|
-
- Gemfile
|
27
|
-
- Gemfile.lock
|
28
24
|
- LICENSE.txt
|
29
25
|
- README.md
|
30
|
-
-
|
26
|
+
- VERSION
|
31
27
|
- bin/buildkite-builder
|
32
28
|
- bin/console
|
33
29
|
- bin/setup
|
34
|
-
- buildkite-builder
|
30
|
+
- exe/buildkite-builder
|
35
31
|
- lib/buildkite-builder.rb
|
36
32
|
- lib/buildkite/builder.rb
|
37
33
|
- lib/buildkite/builder/commands.rb
|
38
34
|
- lib/buildkite/builder/commands/abstract.rb
|
39
35
|
- lib/buildkite/builder/commands/files.rb
|
40
36
|
- lib/buildkite/builder/commands/preview.rb
|
37
|
+
- lib/buildkite/builder/commands/run.rb
|
41
38
|
- lib/buildkite/builder/definition.rb
|
42
39
|
- lib/buildkite/builder/file_resolver.rb
|
43
40
|
- lib/buildkite/builder/github.rb
|
@@ -115,12 +112,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
115
112
|
version: 2.3.0
|
116
113
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
117
114
|
requirements:
|
118
|
-
- - "
|
115
|
+
- - ">="
|
119
116
|
- !ruby/object:Gem::Version
|
120
|
-
version:
|
117
|
+
version: '0'
|
121
118
|
requirements: []
|
122
|
-
rubygems_version: 3.1.
|
119
|
+
rubygems_version: 3.1.2
|
123
120
|
signing_key:
|
124
121
|
specification_version: 4
|
125
|
-
summary:
|
122
|
+
summary: A gem for programmatically creating Buildkite pipelines.
|
126
123
|
test_files: []
|
data/.gitignore
DELETED
data/.rspec
DELETED
data/CODE_OF_CONDUCT.md
DELETED
@@ -1,74 +0,0 @@
|
|
1
|
-
# Contributor Covenant Code of Conduct
|
2
|
-
|
3
|
-
## Our Pledge
|
4
|
-
|
5
|
-
In the interest of fostering an open and welcoming environment, we as
|
6
|
-
contributors and maintainers pledge to making participation in our project and
|
7
|
-
our community a harassment-free experience for everyone, regardless of age, body
|
8
|
-
size, disability, ethnicity, gender identity and expression, level of experience,
|
9
|
-
nationality, personal appearance, race, religion, or sexual identity and
|
10
|
-
orientation.
|
11
|
-
|
12
|
-
## Our Standards
|
13
|
-
|
14
|
-
Examples of behavior that contributes to creating a positive environment
|
15
|
-
include:
|
16
|
-
|
17
|
-
* Using welcoming and inclusive language
|
18
|
-
* Being respectful of differing viewpoints and experiences
|
19
|
-
* Gracefully accepting constructive criticism
|
20
|
-
* Focusing on what is best for the community
|
21
|
-
* Showing empathy towards other community members
|
22
|
-
|
23
|
-
Examples of unacceptable behavior by participants include:
|
24
|
-
|
25
|
-
* The use of sexualized language or imagery and unwelcome sexual attention or
|
26
|
-
advances
|
27
|
-
* Trolling, insulting/derogatory comments, and personal or political attacks
|
28
|
-
* Public or private harassment
|
29
|
-
* Publishing others' private information, such as a physical or electronic
|
30
|
-
address, without explicit permission
|
31
|
-
* Other conduct which could reasonably be considered inappropriate in a
|
32
|
-
professional setting
|
33
|
-
|
34
|
-
## Our Responsibilities
|
35
|
-
|
36
|
-
Project maintainers are responsible for clarifying the standards of acceptable
|
37
|
-
behavior and are expected to take appropriate and fair corrective action in
|
38
|
-
response to any instances of unacceptable behavior.
|
39
|
-
|
40
|
-
Project maintainers have the right and responsibility to remove, edit, or
|
41
|
-
reject comments, commits, code, wiki edits, issues, and other contributions
|
42
|
-
that are not aligned to this Code of Conduct, or to ban temporarily or
|
43
|
-
permanently any contributor for other behaviors that they deem inappropriate,
|
44
|
-
threatening, offensive, or harmful.
|
45
|
-
|
46
|
-
## Scope
|
47
|
-
|
48
|
-
This Code of Conduct applies both within project spaces and in public spaces
|
49
|
-
when an individual is representing the project or its community. Examples of
|
50
|
-
representing a project or community include using an official project e-mail
|
51
|
-
address, posting via an official social media account, or acting as an appointed
|
52
|
-
representative at an online or offline event. Representation of a project may be
|
53
|
-
further defined and clarified by project maintainers.
|
54
|
-
|
55
|
-
## Enforcement
|
56
|
-
|
57
|
-
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
58
|
-
reported by contacting the project team at andrew.lee@gusto.com. All
|
59
|
-
complaints will be reviewed and investigated and will result in a response that
|
60
|
-
is deemed necessary and appropriate to the circumstances. The project team is
|
61
|
-
obligated to maintain confidentiality with regard to the reporter of an incident.
|
62
|
-
Further details of specific enforcement policies may be posted separately.
|
63
|
-
|
64
|
-
Project maintainers who do not follow or enforce the Code of Conduct in good
|
65
|
-
faith may face temporary or permanent repercussions as determined by other
|
66
|
-
members of the project's leadership.
|
67
|
-
|
68
|
-
## Attribution
|
69
|
-
|
70
|
-
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
|
71
|
-
available at [https://contributor-covenant.org/version/1/4][version]
|
72
|
-
|
73
|
-
[homepage]: https://contributor-covenant.org
|
74
|
-
[version]: https://contributor-covenant.org/version/1/4/
|
data/Gemfile
DELETED
data/Gemfile.lock
DELETED
@@ -1,56 +0,0 @@
|
|
1
|
-
PATH
|
2
|
-
remote: .
|
3
|
-
specs:
|
4
|
-
buildkite-builder (1.0.0.beta.1)
|
5
|
-
|
6
|
-
GEM
|
7
|
-
remote: https://rubygems.org/
|
8
|
-
specs:
|
9
|
-
addressable (2.7.0)
|
10
|
-
public_suffix (>= 2.0.2, < 5.0)
|
11
|
-
byebug (11.1.3)
|
12
|
-
coderay (1.1.3)
|
13
|
-
crack (0.4.4)
|
14
|
-
diff-lcs (1.3)
|
15
|
-
hashdiff (1.0.1)
|
16
|
-
method_source (1.0.0)
|
17
|
-
pry (0.13.1)
|
18
|
-
coderay (~> 1.1)
|
19
|
-
method_source (~> 1.0)
|
20
|
-
pry-byebug (3.9.0)
|
21
|
-
byebug (~> 11.0)
|
22
|
-
pry (~> 0.13.0)
|
23
|
-
public_suffix (4.0.6)
|
24
|
-
rake (13.0.1)
|
25
|
-
rspec (3.9.0)
|
26
|
-
rspec-core (~> 3.9.0)
|
27
|
-
rspec-expectations (~> 3.9.0)
|
28
|
-
rspec-mocks (~> 3.9.0)
|
29
|
-
rspec-core (3.9.0)
|
30
|
-
rspec-support (~> 3.9.0)
|
31
|
-
rspec-expectations (3.9.0)
|
32
|
-
diff-lcs (>= 1.2.0, < 2.0)
|
33
|
-
rspec-support (~> 3.9.0)
|
34
|
-
rspec-mocks (3.9.0)
|
35
|
-
diff-lcs (>= 1.2.0, < 2.0)
|
36
|
-
rspec-support (~> 3.9.0)
|
37
|
-
rspec-support (3.9.0)
|
38
|
-
webmock (3.10.0)
|
39
|
-
addressable (>= 2.3.6)
|
40
|
-
crack (>= 0.3.2)
|
41
|
-
hashdiff (>= 0.4.0, < 2.0.0)
|
42
|
-
|
43
|
-
PLATFORMS
|
44
|
-
ruby
|
45
|
-
|
46
|
-
DEPENDENCIES
|
47
|
-
buildkite-builder!
|
48
|
-
bundler (~> 2.1)
|
49
|
-
byebug
|
50
|
-
pry-byebug
|
51
|
-
rake
|
52
|
-
rspec
|
53
|
-
webmock
|
54
|
-
|
55
|
-
BUNDLED WITH
|
56
|
-
2.1.4
|
data/Rakefile
DELETED
data/buildkite-builder.gemspec
DELETED
@@ -1,28 +0,0 @@
|
|
1
|
-
$LOAD_PATH.unshift File.expand_path('lib', __dir__)
|
2
|
-
require 'buildkite-builder'
|
3
|
-
|
4
|
-
Gem::Specification.new do |spec|
|
5
|
-
spec.name = "buildkite-builder"
|
6
|
-
spec.version = Buildkite::Builder::VERSION
|
7
|
-
spec.authors = ["Ngan Pham", "Andrew Lee"]
|
8
|
-
spec.email = ["gusto-opensource-buildkite@gusto.com"]
|
9
|
-
|
10
|
-
spec.summary = %q{Write a short summary, because RubyGems requires one.}
|
11
|
-
spec.description = %q{Write a longer description or delete this line.}
|
12
|
-
spec.homepage = 'https://github.com/Gusto/buildkite-builder'
|
13
|
-
spec.license = 'MIT'
|
14
|
-
spec.required_ruby_version = Gem::Requirement.new(">= 2.3.0")
|
15
|
-
|
16
|
-
spec.metadata["homepage_uri"] = spec.homepage
|
17
|
-
spec.metadata["source_code_uri"] = "https://github.com/Gusto/buildkite-builder"
|
18
|
-
spec.metadata["changelog_uri"] = "https://github.com/Gusto/buildkite-builder/blob/master/CHANGELOG.md"
|
19
|
-
spec.metadata["bug_tracker_uri"] = "https://github.com/Gusto/buildkite-builder/issues"
|
20
|
-
|
21
|
-
# Specify which files should be added to the gem when it is released.
|
22
|
-
# The `git ls-files -z` loads the files in the RubyGem that have been added into git.
|
23
|
-
spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do
|
24
|
-
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
25
|
-
end
|
26
|
-
spec.executables = ['buildkite-builder']
|
27
|
-
spec.require_paths = ["lib"]
|
28
|
-
end
|