rubyjobbuilderdsl 0.0.5 → 0.0.6

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.
Files changed (111) hide show
  1. checksums.yaml +13 -5
  2. data/Gemfile +6 -6
  3. data/Gemfile.lock +41 -41
  4. data/LICENSE +18 -18
  5. data/Rakefile +12 -12
  6. data/docs/common.md +313 -313
  7. data/docs/flow.md +17 -17
  8. data/docs/freestyle.md +100 -100
  9. data/docs/gerrit.md +70 -70
  10. data/docs/git.md +88 -88
  11. data/docs/multi.md +26 -26
  12. data/docs/overview.md +74 -74
  13. data/docs/postbuild.md +266 -266
  14. data/docs/view.md +13 -13
  15. data/lib/rubyjobbuilderdsl.rb +2 -2
  16. data/lib/rubyjobbuilderdsl/buildstep/ant.rb +29 -29
  17. data/lib/rubyjobbuilderdsl/buildstep/copyartifact.rb +23 -23
  18. data/lib/rubyjobbuilderdsl/buildstep/inject_env.rb +18 -18
  19. data/lib/rubyjobbuilderdsl/buildstep/phase.rb +19 -19
  20. data/lib/rubyjobbuilderdsl/buildstep/phase_job.rb +26 -26
  21. data/lib/rubyjobbuilderdsl/buildstep/shell.rb +24 -24
  22. data/lib/rubyjobbuilderdsl/buildstep/xvfb.rb +46 -46
  23. data/lib/rubyjobbuilderdsl/common.rb +140 -140
  24. data/lib/rubyjobbuilderdsl/common/artifactory.rb +33 -33
  25. data/lib/rubyjobbuilderdsl/common/blocking_job.rb +11 -11
  26. data/lib/rubyjobbuilderdsl/common/build_timeout.rb +23 -23
  27. data/lib/rubyjobbuilderdsl/common/gerrit.rb +53 -53
  28. data/lib/rubyjobbuilderdsl/common/git.rb +76 -76
  29. data/lib/rubyjobbuilderdsl/common/logrotate.rb +24 -24
  30. data/lib/rubyjobbuilderdsl/common/parameter.rb +22 -22
  31. data/lib/rubyjobbuilderdsl/common/password.rb +12 -12
  32. data/lib/rubyjobbuilderdsl/common/pollscm.rb +10 -10
  33. data/lib/rubyjobbuilderdsl/common/scms.rb +18 -18
  34. data/lib/rubyjobbuilderdsl/common/throttle.rb +24 -24
  35. data/lib/rubyjobbuilderdsl/common/timed.rb +10 -10
  36. data/lib/rubyjobbuilderdsl/common/timestamps.rb +6 -6
  37. data/lib/rubyjobbuilderdsl/deployer.rb +95 -95
  38. data/lib/rubyjobbuilderdsl/flow.rb +14 -14
  39. data/lib/rubyjobbuilderdsl/freestyle.rb +65 -65
  40. data/lib/rubyjobbuilderdsl/jenkins_client.rb +203 -203
  41. data/lib/rubyjobbuilderdsl/multijob.rb +24 -24
  42. data/lib/rubyjobbuilderdsl/postbuild.rb +160 -160
  43. data/lib/rubyjobbuilderdsl/postbuild/archive.rb +23 -23
  44. data/lib/rubyjobbuilderdsl/postbuild/chucknorris_publisher.rb +6 -6
  45. data/lib/rubyjobbuilderdsl/postbuild/claim_publisher.rb +6 -6
  46. data/lib/rubyjobbuilderdsl/postbuild/cloverphp_publisher.rb +36 -36
  47. data/lib/rubyjobbuilderdsl/postbuild/cucumber_json_publisher.rb +20 -20
  48. data/lib/rubyjobbuilderdsl/postbuild/email_publisher.rb +23 -23
  49. data/lib/rubyjobbuilderdsl/postbuild/game_publisher.rb +6 -6
  50. data/lib/rubyjobbuilderdsl/postbuild/groovy.rb +10 -10
  51. data/lib/rubyjobbuilderdsl/postbuild/html_publisher.rb +27 -27
  52. data/lib/rubyjobbuilderdsl/postbuild/javadoc_publisher.rb +19 -19
  53. data/lib/rubyjobbuilderdsl/postbuild/logparser.rb +21 -21
  54. data/lib/rubyjobbuilderdsl/postbuild/nunit_publisher.rb +21 -21
  55. data/lib/rubyjobbuilderdsl/postbuild/pmd_publisher.rb +19 -19
  56. data/lib/rubyjobbuilderdsl/postbuild/script.rb +14 -14
  57. data/lib/rubyjobbuilderdsl/postbuild/tap_publisher.rb +44 -44
  58. data/lib/rubyjobbuilderdsl/postbuild/trigger.rb +38 -38
  59. data/lib/rubyjobbuilderdsl/postbuild/xunit_publisher.rb +35 -35
  60. data/lib/rubyjobbuilderdsl/view.rb +14 -14
  61. data/lib/rubyjobbuilderdsl/xml_generator.rb +1 -1
  62. data/rubyjobbuilderdsl.gemspec +2 -2
  63. data/rubyjobbuilderdsl.sublime-project +14 -14
  64. data/run_tests.sh +7 -7
  65. data/sample/hello_mars.rb +27 -27
  66. data/sample/hello_mars.xml +18 -0
  67. data/sample/hello_world-post.xml +40 -0
  68. data/sample/local.ini +4 -4
  69. data/sample/test.xml +21 -0
  70. data/test/test_ant.rb +38 -38
  71. data/test/test_archive.rb +24 -24
  72. data/test/test_artifactory.rb +26 -26
  73. data/test/test_blocking_job.rb +18 -18
  74. data/test/test_chucknorris_publisher.rb +17 -17
  75. data/test/test_claim_publisher.rb +17 -17
  76. data/test/test_cloverphp.rb +33 -33
  77. data/test/test_concurrent.rb +44 -44
  78. data/test/test_copyartifact.rb +45 -45
  79. data/test/test_cucumber_json_publisher.rb +30 -30
  80. data/test/test_default_setting.rb +29 -29
  81. data/test/test_email_publisher.rb +44 -44
  82. data/test/test_flow.rb +19 -19
  83. data/test/test_freestyle.rb +52 -52
  84. data/test/test_game_publisher.rb +17 -17
  85. data/test/test_gerrit.rb +117 -117
  86. data/test/test_git.rb +80 -80
  87. data/test/test_html_publisher.rb +57 -57
  88. data/test/test_inject.rb +23 -23
  89. data/test/test_javadoc.rb +22 -22
  90. data/test/test_logparser.rb +24 -24
  91. data/test/test_logrotate.rb +22 -22
  92. data/test/test_multijob.rb +50 -50
  93. data/test/test_nunit_publisher.rb +20 -20
  94. data/test/test_parameter.rb +44 -44
  95. data/test/test_password.rb +17 -17
  96. data/test/test_pmd.rb +22 -22
  97. data/test/test_pollscm.rb +15 -15
  98. data/test/test_postbuild_groovy.rb +21 -21
  99. data/test/test_postbuild_script.rb +24 -24
  100. data/test/test_postbuild_trigger.rb +170 -170
  101. data/test/test_scms.rb +31 -31
  102. data/test/test_tap_publisher.rb +25 -25
  103. data/test/test_timed.rb +15 -15
  104. data/test/test_timeout.rb +20 -20
  105. data/test/test_timestamps.rb +14 -14
  106. data/test/test_xml_generator.rb +28 -28
  107. data/test/test_xunit_publisher.rb +22 -22
  108. data/test/test_xvfb.rb +35 -35
  109. metadata +11 -10
  110. data/rubyjobbuilderdsl-0.0.3.gem +0 -0
  111. data/sample/Schedule-sample-pipeline.xml +0 -32
data/docs/view.md CHANGED
@@ -1,13 +1,13 @@
1
- ## Create view
2
-
3
- **view**
4
-
5
- Description: create a list view
6
-
7
- Multiple: Add
8
-
9
- Example
10
-
11
- builder.view 'test' do
12
- job 'test-.*'
13
- end
1
+ ## Create view
2
+
3
+ **view**
4
+
5
+ Description: create a list view
6
+
7
+ Multiple: Add
8
+
9
+ Example
10
+
11
+ builder.view 'test' do
12
+ job 'test-.*'
13
+ end
@@ -1,2 +1,2 @@
1
- require_relative './rubyjobbuilderdsl/builder'
2
- require_relative './rubyjobbuilderdsl/deployer'
1
+ require_relative './rubyjobbuilderdsl/builder'
2
+ require_relative './rubyjobbuilderdsl/deployer'
@@ -1,29 +1,29 @@
1
- module JenkinsJob
2
- module BuildStep
3
- class Ant < BasicObject
4
- attr_reader :targets_, :buildfile_, :properties_, :java_opts_
5
-
6
- def initialize
7
- @targets_ = []
8
- @properties_ = {}
9
- @java_opts_ = []
10
- end
11
-
12
- def target(*value)
13
- @targets_ = value
14
- end
15
-
16
- def buildfile(value)
17
- @buildfile_ = value
18
- end
19
-
20
- def property(value)
21
- @properties_ = value
22
- end
23
-
24
- def java_opts(*value)
25
- @java_opts_ = value
26
- end
27
- end
28
- end
29
- end
1
+ module JenkinsJob
2
+ module BuildStep
3
+ class Ant < BasicObject
4
+ attr_reader :targets_, :buildfile_, :properties_, :java_opts_
5
+
6
+ def initialize
7
+ @targets_ = []
8
+ @properties_ = {}
9
+ @java_opts_ = []
10
+ end
11
+
12
+ def target(*value)
13
+ @targets_ = value
14
+ end
15
+
16
+ def buildfile(value)
17
+ @buildfile_ = value
18
+ end
19
+
20
+ def property(value)
21
+ @properties_ = value
22
+ end
23
+
24
+ def java_opts(*value)
25
+ @java_opts_ = value
26
+ end
27
+ end
28
+ end
29
+ end
@@ -1,23 +1,23 @@
1
- module JenkinsJob
2
- module BuildStep
3
- class CopyArtifact < BasicObject
4
- attr_reader :project_, :filter_, :target_, :build_number_
5
-
6
- def initialize(artifact_job)
7
- @project_ = artifact_job
8
- end
9
-
10
- def file(*files)
11
- @filter_ = files.join(',')
12
- end
13
-
14
- def to(dir)
15
- @target_ = dir
16
- end
17
-
18
- def build_number(value = nil)
19
- @build_number_ = value
20
- end
21
- end
22
- end
23
- end
1
+ module JenkinsJob
2
+ module BuildStep
3
+ class CopyArtifact < BasicObject
4
+ attr_reader :project_, :filter_, :target_, :build_number_
5
+
6
+ def initialize(artifact_job)
7
+ @project_ = artifact_job
8
+ end
9
+
10
+ def file(*files)
11
+ @filter_ = files.join(',')
12
+ end
13
+
14
+ def to(dir)
15
+ @target_ = dir
16
+ end
17
+
18
+ def build_number(value = nil)
19
+ @build_number_ = value
20
+ end
21
+ end
22
+ end
23
+ end
@@ -1,18 +1,18 @@
1
- module JenkinsJob
2
- module BuildStep
3
- class InjectEnv < BasicObject
4
- attr_reader :properties_content_, :properties_file_
5
-
6
- def initialize
7
- end
8
-
9
- def properties_content(value)
10
- @properties_content_ = value
11
- end
12
-
13
- def properties_file(value)
14
- @properties_file_ = value
15
- end
16
- end
17
- end
18
- end
1
+ module JenkinsJob
2
+ module BuildStep
3
+ class InjectEnv < BasicObject
4
+ attr_reader :properties_content_, :properties_file_
5
+
6
+ def initialize
7
+ end
8
+
9
+ def properties_content(value)
10
+ @properties_content_ = value
11
+ end
12
+
13
+ def properties_file(value)
14
+ @properties_file_ = value
15
+ end
16
+ end
17
+ end
18
+ end
@@ -1,19 +1,19 @@
1
- module JenkinsJob
2
- module BuildStep
3
- class Phase < BasicObject
4
- attr_reader :name, :jobs_
5
-
6
- def initialize(name)
7
- @name = name
8
- @jobs_ = []
9
- end
10
-
11
- def job(name, &block)
12
- job = PhaseJob.new(name)
13
- job.instance_eval(&block) if block
14
-
15
- @jobs_ << job
16
- end
17
- end
18
- end
19
- end
1
+ module JenkinsJob
2
+ module BuildStep
3
+ class Phase < BasicObject
4
+ attr_reader :name, :jobs_
5
+
6
+ def initialize(name)
7
+ @name = name
8
+ @jobs_ = []
9
+ end
10
+
11
+ def job(name, &block)
12
+ job = PhaseJob.new(name)
13
+ job.instance_eval(&block) if block
14
+
15
+ @jobs_ << job
16
+ end
17
+ end
18
+ end
19
+ end
@@ -1,26 +1,26 @@
1
- module JenkinsJob
2
- module BuildStep
3
- class PhaseJob < BasicObject
4
- attr_reader :name, :ignore_result_, :retries_, :abort_others_
5
-
6
- def initialize(name)
7
- @name = name
8
- @ignore_result_ = false
9
- @retries_ = 0
10
- @abort_others_ = false
11
- end
12
-
13
- def ignore_result(value = true)
14
- @ignore_result_ = value
15
- end
16
-
17
- def retries(value)
18
- @retries_ = value
19
- end
20
-
21
- def abort_others(value = true)
22
- @abort_others_ = value
23
- end
24
- end
25
- end
26
- end
1
+ module JenkinsJob
2
+ module BuildStep
3
+ class PhaseJob < BasicObject
4
+ attr_reader :name, :ignore_result_, :retries_, :abort_others_
5
+
6
+ def initialize(name)
7
+ @name = name
8
+ @ignore_result_ = false
9
+ @retries_ = 0
10
+ @abort_others_ = false
11
+ end
12
+
13
+ def ignore_result(value = true)
14
+ @ignore_result_ = value
15
+ end
16
+
17
+ def retries(value)
18
+ @retries_ = value
19
+ end
20
+
21
+ def abort_others(value = true)
22
+ @abort_others_ = value
23
+ end
24
+ end
25
+ end
26
+ end
@@ -1,24 +1,24 @@
1
- module JenkinsJob
2
- module BuildStep
3
- class Shell < BasicObject
4
- attr_reader :cmd_
5
- def initialize(cmd)
6
- @cmd_ = cmd
7
- end
8
- end
9
-
10
- class Batch < BasicObject
11
- attr_reader :cmd_
12
- def initialize(cmd)
13
- @cmd_ = cmd
14
- end
15
- end
16
-
17
- class Powershell < BasicObject
18
- attr_reader :cmd_
19
- def initialize(cmd)
20
- @cmd_ = cmd
21
- end
22
- end
23
- end
24
- end
1
+ module JenkinsJob
2
+ module BuildStep
3
+ class Shell < BasicObject
4
+ attr_reader :cmd_
5
+ def initialize(cmd)
6
+ @cmd_ = cmd
7
+ end
8
+ end
9
+
10
+ class Batch < BasicObject
11
+ attr_reader :cmd_
12
+ def initialize(cmd)
13
+ @cmd_ = cmd
14
+ end
15
+ end
16
+
17
+ class Powershell < BasicObject
18
+ attr_reader :cmd_
19
+ def initialize(cmd)
20
+ @cmd_ = cmd
21
+ end
22
+ end
23
+ end
24
+ end
@@ -1,46 +1,46 @@
1
- module JenkinsJob
2
- module BuildStep
3
- class Xvfb < BasicObject
4
- attr_reader :install_name_, :screen_, :debug_, :timeout_, :display_name_offset_, :shutdown_with_build_, :auto_display_name_, :parallel_build_
5
-
6
- def initialize
7
- @install_name_ = 'Xvfb'
8
- @screen_ = '1024x768x24'
9
- @debug_ = false
10
- @timeout_ = 0
11
- @display_name_offset_ = 1
12
- @shutdown_with_build_ = false
13
- @auto_display_name_ = true
14
- @parallel_build_ = false
15
- end
16
-
17
- def install_name(value)
18
- @install_name_ = value
19
- end
20
-
21
- def screen(value)
22
- @screen_ = value
23
- end
24
-
25
- def timeout(value)
26
- @timeout_ = value
27
- end
28
-
29
- def display_name_offset(value)
30
- @display_name_offset_ = value
31
- end
32
-
33
- def shutdown_with_build(value)
34
- @shutdown_with_build_ = value
35
- end
36
-
37
- def auto_display_name(value)
38
- @auto_display_name_ = value
39
- end
40
-
41
- def parallel_build(value)
42
- @parallel_build_ = value
43
- end
44
- end
45
- end
46
- end
1
+ module JenkinsJob
2
+ module BuildStep
3
+ class Xvfb < BasicObject
4
+ attr_reader :install_name_, :screen_, :debug_, :timeout_, :display_name_offset_, :shutdown_with_build_, :auto_display_name_, :parallel_build_
5
+
6
+ def initialize
7
+ @install_name_ = 'Xvfb'
8
+ @screen_ = '1024x768x24'
9
+ @debug_ = false
10
+ @timeout_ = 0
11
+ @display_name_offset_ = 1
12
+ @shutdown_with_build_ = false
13
+ @auto_display_name_ = true
14
+ @parallel_build_ = false
15
+ end
16
+
17
+ def install_name(value)
18
+ @install_name_ = value
19
+ end
20
+
21
+ def screen(value)
22
+ @screen_ = value
23
+ end
24
+
25
+ def timeout(value)
26
+ @timeout_ = value
27
+ end
28
+
29
+ def display_name_offset(value)
30
+ @display_name_offset_ = value
31
+ end
32
+
33
+ def shutdown_with_build(value)
34
+ @shutdown_with_build_ = value
35
+ end
36
+
37
+ def auto_display_name(value)
38
+ @auto_display_name_ = value
39
+ end
40
+
41
+ def parallel_build(value)
42
+ @parallel_build_ = value
43
+ end
44
+ end
45
+ end
46
+ end
@@ -1,140 +1,140 @@
1
- require_relative 'common/parameter'
2
- require_relative 'common/git'
3
- require_relative 'common/gerrit'
4
- require_relative 'common/logrotate'
5
- require_relative 'common/scms'
6
- require_relative 'common/throttle'
7
- require_relative 'common/build_timeout'
8
- require_relative 'common/artifactory'
9
- require_relative 'common/pollscm'
10
- require_relative 'common/timed'
11
- require_relative 'common/password'
12
- require_relative 'common/timestamps'
13
- require_relative 'common/blocking_job'
14
- require_relative 'postbuild'
15
-
16
- module JenkinsJob
17
- module Common
18
- class Common
19
- attr_reader :builder,
20
- :node_, :quiet_period_, :logrotate_,
21
- :parameters_, :postbuild_, :scm_,
22
- :triggers_, :concurrent_, :wrappers_, :properties_,
23
- :desc_
24
-
25
- def initialize(builder)
26
- @builder = builder
27
- @triggers_ = {}
28
- @wrappers_ = {}
29
- @properties_ = {}
30
- @parameters_ = {}
31
- @concurrent_ = false
32
- end
33
-
34
- def node(value)
35
- @node_ = value
36
- end
37
-
38
- def quiet_period(value)
39
- @quiet_period_ = value
40
- end
41
-
42
- def logrotate(&block)
43
- rotate = LogRotate.new
44
- rotate.instance_eval(&block)
45
- @logrotate_ = rotate
46
- end
47
-
48
- def parameter(name, &block)
49
- param = Parameter.new(name)
50
- param.instance_eval(&block) if block_given?
51
-
52
- @parameters_[name] = param
53
- end
54
-
55
- def password_parameter(name, &block)
56
- param = PasswordParameter.new(name)
57
- param.instance_eval(&block) if block_given?
58
-
59
- @parameters_[name] = param
60
- end
61
-
62
- def postbuild(&block)
63
- @postbuild_ = ::JenkinsJob::Postbuild::Postbuild.new(self) unless @postbuild_
64
- @postbuild_.instance_eval(&block)
65
- end
66
-
67
- def git(&block)
68
- git = Git.new
69
- git.instance_eval(&block)
70
-
71
- @scm_ = git
72
- end
73
-
74
- def scms(&block)
75
- scms = Scms.new
76
- scms.instance_eval(&block)
77
-
78
- @scm_ = scms
79
- end
80
-
81
- def gerrit(&block)
82
- gerrit = Gerrit.new
83
- gerrit.instance_eval(&block)
84
-
85
- @triggers_['gerrit'] = gerrit
86
- end
87
-
88
- def pollscm(value)
89
- @triggers_['pollscm'] = PollSCM.new(value)
90
- end
91
-
92
- def timed(value)
93
- @triggers_['timed'] = Timed.new(value)
94
- end
95
-
96
- def concurrent(&block)
97
- @concurrent_ = true
98
-
99
- throttle = Throttle.new
100
- throttle.instance_eval(&block)
101
-
102
- @properties_['throttle'] = throttle
103
- end
104
-
105
- def timestamps
106
- @wrappers_['timestamp'] = Timestamps.new
107
- end
108
-
109
- def timeout(type, &block)
110
- build_timeout = BuildTimeout.new(type)
111
- build_timeout.instance_eval(&block)
112
-
113
- @wrappers_['timeout'] = build_timeout
114
- end
115
-
116
- def artifactory(&block)
117
- artifact = Artifactory.new
118
- artifact.instance_eval(&block)
119
-
120
- @wrappers_['artifactory'] = artifact
121
- end
122
-
123
- def password(name, password)
124
- password = Password.new(name, password)
125
-
126
- @wrappers_['password'] = password
127
- end
128
-
129
- def blocked_by(*value)
130
- blocking_job = BlockingJob.new(value)
131
-
132
- @properties_['blocking_job'] = blocking_job
133
- end
134
-
135
- def desc(value)
136
- @desc_ = value
137
- end
138
- end
139
- end
140
- end
1
+ require_relative 'common/parameter'
2
+ require_relative 'common/git'
3
+ require_relative 'common/gerrit'
4
+ require_relative 'common/logrotate'
5
+ require_relative 'common/scms'
6
+ require_relative 'common/throttle'
7
+ require_relative 'common/build_timeout'
8
+ require_relative 'common/artifactory'
9
+ require_relative 'common/pollscm'
10
+ require_relative 'common/timed'
11
+ require_relative 'common/password'
12
+ require_relative 'common/timestamps'
13
+ require_relative 'common/blocking_job'
14
+ require_relative 'postbuild'
15
+
16
+ module JenkinsJob
17
+ module Common
18
+ class Common
19
+ attr_reader :builder,
20
+ :node_, :quiet_period_, :logrotate_,
21
+ :parameters_, :postbuild_, :scm_,
22
+ :triggers_, :concurrent_, :wrappers_, :properties_,
23
+ :desc_
24
+
25
+ def initialize(builder)
26
+ @builder = builder
27
+ @triggers_ = {}
28
+ @wrappers_ = {}
29
+ @properties_ = {}
30
+ @parameters_ = {}
31
+ @concurrent_ = false
32
+ end
33
+
34
+ def node(value)
35
+ @node_ = value
36
+ end
37
+
38
+ def quiet_period(value)
39
+ @quiet_period_ = value
40
+ end
41
+
42
+ def logrotate(&block)
43
+ rotate = LogRotate.new
44
+ rotate.instance_eval(&block)
45
+ @logrotate_ = rotate
46
+ end
47
+
48
+ def parameter(name, &block)
49
+ param = Parameter.new(name)
50
+ param.instance_eval(&block) if block_given?
51
+
52
+ @parameters_[name] = param
53
+ end
54
+
55
+ def password_parameter(name, &block)
56
+ param = PasswordParameter.new(name)
57
+ param.instance_eval(&block) if block_given?
58
+
59
+ @parameters_[name] = param
60
+ end
61
+
62
+ def postbuild(&block)
63
+ @postbuild_ = ::JenkinsJob::Postbuild::Postbuild.new(self) unless @postbuild_
64
+ @postbuild_.instance_eval(&block)
65
+ end
66
+
67
+ def git(&block)
68
+ git = Git.new
69
+ git.instance_eval(&block)
70
+
71
+ @scm_ = git
72
+ end
73
+
74
+ def scms(&block)
75
+ scms = Scms.new
76
+ scms.instance_eval(&block)
77
+
78
+ @scm_ = scms
79
+ end
80
+
81
+ def gerrit(&block)
82
+ gerrit = Gerrit.new
83
+ gerrit.instance_eval(&block)
84
+
85
+ @triggers_['gerrit'] = gerrit
86
+ end
87
+
88
+ def pollscm(value)
89
+ @triggers_['pollscm'] = PollSCM.new(value)
90
+ end
91
+
92
+ def timed(value)
93
+ @triggers_['timed'] = Timed.new(value)
94
+ end
95
+
96
+ def concurrent(&block)
97
+ @concurrent_ = true
98
+
99
+ throttle = Throttle.new
100
+ throttle.instance_eval(&block)
101
+
102
+ @properties_['throttle'] = throttle
103
+ end
104
+
105
+ def timestamps
106
+ @wrappers_['timestamp'] = Timestamps.new
107
+ end
108
+
109
+ def timeout(type, &block)
110
+ build_timeout = BuildTimeout.new(type)
111
+ build_timeout.instance_eval(&block)
112
+
113
+ @wrappers_['timeout'] = build_timeout
114
+ end
115
+
116
+ def artifactory(&block)
117
+ artifact = Artifactory.new
118
+ artifact.instance_eval(&block)
119
+
120
+ @wrappers_['artifactory'] = artifact
121
+ end
122
+
123
+ def password(name, password)
124
+ password = Password.new(name, password)
125
+
126
+ @wrappers_['password'] = password
127
+ end
128
+
129
+ def blocked_by(*value)
130
+ blocking_job = BlockingJob.new(value)
131
+
132
+ @properties_['blocking_job'] = blocking_job
133
+ end
134
+
135
+ def desc(value)
136
+ @desc_ = value
137
+ end
138
+ end
139
+ end
140
+ end