ruby-terraform 0.65.0.pre.6 → 0.65.0.pre.7
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/Gemfile.lock +1 -1
- data/lib/ruby_terraform.rb +1 -0
- data/lib/ruby_terraform/commands/apply.rb +15 -3
- data/lib/ruby_terraform/commands/base.rb +2 -2
- data/lib/ruby_terraform/commands/destroy.rb +11 -2
- data/lib/ruby_terraform/commands/format.rb +9 -2
- data/lib/ruby_terraform/commands/get.rb +5 -2
- data/lib/ruby_terraform/commands/import.rb +10 -2
- data/lib/ruby_terraform/commands/init.rb +10 -3
- data/lib/ruby_terraform/commands/output.rb +8 -2
- data/lib/ruby_terraform/commands/plan.rb +11 -2
- data/lib/ruby_terraform/commands/refresh.rb +9 -2
- data/lib/ruby_terraform/commands/remote_config.rb +6 -2
- data/lib/ruby_terraform/commands/show.rb +6 -2
- data/lib/ruby_terraform/commands/validate.rb +9 -2
- data/lib/ruby_terraform/commands/workspace.rb +1 -1
- data/lib/ruby_terraform/options.rb +5 -0
- data/lib/ruby_terraform/options/factory.rb +64 -64
- data/lib/ruby_terraform/options/{switch.rb → name.rb} +9 -7
- data/lib/ruby_terraform/options/types/base.rb +24 -0
- data/lib/ruby_terraform/options/types/boolean.rb +16 -0
- data/lib/ruby_terraform/options/types/flag.rb +16 -0
- data/lib/ruby_terraform/options/types/standard.rb +41 -0
- data/lib/ruby_terraform/version.rb +1 -1
- metadata +7 -6
- data/lib/ruby_terraform/options/base.rb +0 -22
- data/lib/ruby_terraform/options/boolean.rb +0 -14
- data/lib/ruby_terraform/options/flag.rb +0 -14
- data/lib/ruby_terraform/options/standard.rb +0 -39
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9addf5887a0f81258238fceea9f31f92f8653b4593c0684e3511723e5d7ee969
|
4
|
+
data.tar.gz: 660b6fb332e8b93e4ca3f7bb8dc1b48052a2116130273968d148d983b9ee0f4f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 444f51e2e53816404a78770d21873b060b2b117fe36a34516c1c1748db60d87ed10a1fa07bd75e0d7ff010617b1ce7ed3618ede7bc80263539be6454a703b962
|
7
|
+
data.tar.gz: cbb17a6a9b74be5a809b3d68058f383634482fdc3aa06151fc70b165195f230dd692da4b8494a20ffbe09bb7075acd15d9238b07a8a5dc53c3d4590990369000
|
data/Gemfile.lock
CHANGED
data/lib/ruby_terraform.rb
CHANGED
@@ -3,14 +3,26 @@ require_relative 'base'
|
|
3
3
|
module RubyTerraform
|
4
4
|
module Commands
|
5
5
|
class Apply < Base
|
6
|
-
def
|
6
|
+
def subcommands(_values)
|
7
7
|
%w[apply]
|
8
8
|
end
|
9
9
|
|
10
|
+
# rubocop:disable Metrics/MethodLength
|
10
11
|
def switches
|
11
|
-
%w[
|
12
|
-
|
12
|
+
%w[
|
13
|
+
-auto-approve
|
14
|
+
-backup
|
15
|
+
-input
|
16
|
+
-lock
|
17
|
+
-lock-timeout
|
18
|
+
-no-color
|
19
|
+
-state
|
20
|
+
-target
|
21
|
+
-var
|
22
|
+
-var-file
|
23
|
+
]
|
13
24
|
end
|
25
|
+
# rubocop:enable Metrics/MethodLength
|
14
26
|
|
15
27
|
def arguments(values)
|
16
28
|
[values[:plan] || values[:directory]]
|
@@ -61,7 +61,7 @@ module RubyTerraform
|
|
61
61
|
.with_options_after_subcommands
|
62
62
|
.with_option_separator('=')
|
63
63
|
.with_appliables(options(values))
|
64
|
-
.with_subcommands(
|
64
|
+
.with_subcommands(subcommands(values))
|
65
65
|
.with_arguments(arguments(values))
|
66
66
|
.build
|
67
67
|
end
|
@@ -80,7 +80,7 @@ module RubyTerraform
|
|
80
80
|
{}
|
81
81
|
end
|
82
82
|
|
83
|
-
def
|
83
|
+
def subcommands(_values)
|
84
84
|
[]
|
85
85
|
end
|
86
86
|
|
@@ -4,10 +4,19 @@ module RubyTerraform
|
|
4
4
|
module Commands
|
5
5
|
class Destroy < Base
|
6
6
|
def switches
|
7
|
-
%w[
|
7
|
+
%w[
|
8
|
+
-auto-approve
|
9
|
+
-backup
|
10
|
+
-force
|
11
|
+
-no-color
|
12
|
+
-state
|
13
|
+
-target
|
14
|
+
-var
|
15
|
+
-var-file
|
16
|
+
]
|
8
17
|
end
|
9
18
|
|
10
|
-
def
|
19
|
+
def subcommands(_values)
|
11
20
|
%w[destroy]
|
12
21
|
end
|
13
22
|
|
@@ -4,10 +4,17 @@ module RubyTerraform
|
|
4
4
|
module Commands
|
5
5
|
class Format < Base
|
6
6
|
def switches
|
7
|
-
%w[
|
7
|
+
%w[
|
8
|
+
-check
|
9
|
+
-diff
|
10
|
+
-list
|
11
|
+
-no-color
|
12
|
+
-recursive
|
13
|
+
-write
|
14
|
+
]
|
8
15
|
end
|
9
16
|
|
10
|
-
def
|
17
|
+
def subcommands(_values)
|
11
18
|
%w[fmt]
|
12
19
|
end
|
13
20
|
|
@@ -4,10 +4,18 @@ module RubyTerraform
|
|
4
4
|
module Commands
|
5
5
|
class Import < Base
|
6
6
|
def switches
|
7
|
-
%w[
|
7
|
+
%w[
|
8
|
+
-config
|
9
|
+
-backup
|
10
|
+
-input
|
11
|
+
-no-color
|
12
|
+
-state
|
13
|
+
-var
|
14
|
+
-var-file
|
15
|
+
]
|
8
16
|
end
|
9
17
|
|
10
|
-
def
|
18
|
+
def subcommands(_values)
|
11
19
|
%w[import]
|
12
20
|
end
|
13
21
|
|
@@ -4,11 +4,18 @@ module RubyTerraform
|
|
4
4
|
module Commands
|
5
5
|
class Init < Base
|
6
6
|
def switches
|
7
|
-
%w[
|
8
|
-
|
7
|
+
%w[
|
8
|
+
-backend
|
9
|
+
-backend-config
|
10
|
+
-force-copy
|
11
|
+
-from-module
|
12
|
+
-get
|
13
|
+
-no-color
|
14
|
+
-plugin-dir
|
15
|
+
]
|
9
16
|
end
|
10
17
|
|
11
|
-
def
|
18
|
+
def subcommands(_values)
|
12
19
|
%w[init]
|
13
20
|
end
|
14
21
|
|
@@ -11,10 +11,16 @@ module RubyTerraform
|
|
11
11
|
end
|
12
12
|
|
13
13
|
def switches
|
14
|
-
%w[
|
14
|
+
%w[
|
15
|
+
-json
|
16
|
+
-module
|
17
|
+
-no-color
|
18
|
+
-raw
|
19
|
+
-state
|
20
|
+
]
|
15
21
|
end
|
16
22
|
|
17
|
-
def
|
23
|
+
def subcommands(_values)
|
18
24
|
%w[output]
|
19
25
|
end
|
20
26
|
|
@@ -4,10 +4,19 @@ module RubyTerraform
|
|
4
4
|
module Commands
|
5
5
|
class Plan < Base
|
6
6
|
def switches
|
7
|
-
%w[
|
7
|
+
%w[
|
8
|
+
-destroy
|
9
|
+
-input
|
10
|
+
-no-color
|
11
|
+
-out
|
12
|
+
-state
|
13
|
+
-target
|
14
|
+
-var
|
15
|
+
-var-file
|
16
|
+
]
|
8
17
|
end
|
9
18
|
|
10
|
-
def
|
19
|
+
def subcommands(_values)
|
11
20
|
%w[plan]
|
12
21
|
end
|
13
22
|
|
@@ -4,10 +4,17 @@ module RubyTerraform
|
|
4
4
|
module Commands
|
5
5
|
class Refresh < Base
|
6
6
|
def switches
|
7
|
-
%w[
|
7
|
+
%w[
|
8
|
+
-input
|
9
|
+
-no-color
|
10
|
+
-state
|
11
|
+
-target
|
12
|
+
-var
|
13
|
+
-var-file
|
14
|
+
]
|
8
15
|
end
|
9
16
|
|
10
|
-
def
|
17
|
+
def subcommands(_values)
|
11
18
|
%w[refresh]
|
12
19
|
end
|
13
20
|
|
@@ -4,10 +4,14 @@ module RubyTerraform
|
|
4
4
|
module Commands
|
5
5
|
class RemoteConfig < Base
|
6
6
|
def switches
|
7
|
-
%w[
|
7
|
+
%w[
|
8
|
+
-backend
|
9
|
+
-backend-config
|
10
|
+
-no-color
|
11
|
+
]
|
8
12
|
end
|
9
13
|
|
10
|
-
def
|
14
|
+
def subcommands(_values)
|
11
15
|
%w[remote config]
|
12
16
|
end
|
13
17
|
|
@@ -4,10 +4,17 @@ module RubyTerraform
|
|
4
4
|
module Commands
|
5
5
|
class Validate < Base
|
6
6
|
def switches
|
7
|
-
%w[
|
7
|
+
%w[
|
8
|
+
-check-variables
|
9
|
+
-json
|
10
|
+
-no-color
|
11
|
+
-state
|
12
|
+
-var
|
13
|
+
-var-file
|
14
|
+
]
|
8
15
|
end
|
9
16
|
|
10
|
-
def
|
17
|
+
def subcommands(_values)
|
11
18
|
%w[validate]
|
12
19
|
end
|
13
20
|
|
@@ -3,7 +3,7 @@ require_relative 'base'
|
|
3
3
|
module RubyTerraform
|
4
4
|
module Commands
|
5
5
|
class Workspace < Base
|
6
|
-
def
|
6
|
+
def subcommands(values)
|
7
7
|
commands = ['workspace', values[:operation]]
|
8
8
|
if values[:workspace] && values[:operation] != 'list'
|
9
9
|
commands << values[:workspace]
|
@@ -1,61 +1,61 @@
|
|
1
|
-
require_relative '
|
2
|
-
require_relative 'boolean'
|
3
|
-
require_relative 'flag'
|
4
|
-
require_relative 'standard'
|
1
|
+
require_relative 'name'
|
2
|
+
require_relative 'types/boolean'
|
3
|
+
require_relative 'types/flag'
|
4
|
+
require_relative 'types/standard'
|
5
5
|
|
6
6
|
module RubyTerraform
|
7
7
|
module Options
|
8
8
|
class Factory
|
9
|
-
|
9
|
+
PLURAL_OPTIONS =
|
10
10
|
Set.new(
|
11
11
|
%w[
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
12
|
+
-var
|
13
|
+
-target
|
14
|
+
-var-file
|
15
|
+
]
|
16
16
|
).freeze
|
17
17
|
|
18
|
-
|
18
|
+
BOOLEAN_OPTIONS =
|
19
19
|
Set.new(
|
20
20
|
%w[
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
21
|
+
-auto-approve
|
22
|
+
-backend
|
23
|
+
-get
|
24
|
+
-get-plugins
|
25
|
+
-input
|
26
|
+
-list
|
27
|
+
-lock
|
28
|
+
-refresh
|
29
|
+
-upgrade
|
30
|
+
-verify-plugins
|
31
|
+
-write
|
32
|
+
]
|
33
33
|
).freeze
|
34
34
|
|
35
|
-
|
35
|
+
FLAG_OPTIONS =
|
36
36
|
Set.new(
|
37
37
|
%w[
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
38
|
+
-allow-missing
|
39
|
+
-allow-missing-config
|
40
|
+
-check
|
41
|
+
-compact-warnings
|
42
|
+
-destroy
|
43
|
+
-detailed-exitcode
|
44
|
+
-diff
|
45
|
+
-draw-cycles
|
46
|
+
-force
|
47
|
+
-force-copy
|
48
|
+
-ignore-remote-version
|
49
|
+
-json
|
50
|
+
-no-color
|
51
|
+
-raw
|
52
|
+
-reconfigure
|
53
|
+
-recursive
|
54
|
+
-update
|
55
|
+
]
|
56
56
|
).freeze
|
57
57
|
|
58
|
-
|
58
|
+
OVERRIDE_OPTIONS =
|
59
59
|
{
|
60
60
|
config: :directory,
|
61
61
|
out: :plan
|
@@ -67,49 +67,49 @@ module RubyTerraform
|
|
67
67
|
|
68
68
|
private_class_method :new
|
69
69
|
|
70
|
-
def initialize(values,
|
71
|
-
@
|
70
|
+
def initialize(values, names)
|
71
|
+
@names = names.map { |switch| Name.new(switch) }
|
72
72
|
@values = values
|
73
73
|
end
|
74
74
|
|
75
75
|
def from
|
76
|
-
|
77
|
-
options.append(*
|
76
|
+
names.each_with_object([]) do |name, options|
|
77
|
+
options.append(*options_from_name(name))
|
78
78
|
end
|
79
79
|
end
|
80
80
|
|
81
81
|
private
|
82
82
|
|
83
|
-
attr_reader :
|
83
|
+
attr_reader :names, :values
|
84
84
|
|
85
|
-
def
|
86
|
-
return plural_options(
|
87
|
-
return boolean_option(
|
88
|
-
return flag_option(
|
89
|
-
return override_option(
|
85
|
+
def options_from_name(name)
|
86
|
+
return plural_options(name) if PLURAL_OPTIONS.include?(name)
|
87
|
+
return boolean_option(name) if BOOLEAN_OPTIONS.include?(name)
|
88
|
+
return flag_option(name) if FLAG_OPTIONS.include?(name)
|
89
|
+
return override_option(name) if OVERRIDE_OPTIONS.key?(name.as_key)
|
90
90
|
|
91
|
-
standard_option(
|
91
|
+
standard_option(name, name.as_key)
|
92
92
|
end
|
93
93
|
|
94
|
-
def boolean_option(
|
95
|
-
[Boolean.new(
|
94
|
+
def boolean_option(name)
|
95
|
+
[Types::Boolean.new(name.to_s, values[name.as_key])]
|
96
96
|
end
|
97
97
|
|
98
|
-
def flag_option(
|
99
|
-
[Flag.new(
|
98
|
+
def flag_option(name)
|
99
|
+
[Types::Flag.new(name.to_s, values[name.as_key])]
|
100
100
|
end
|
101
101
|
|
102
|
-
def standard_option(
|
103
|
-
[Standard.new(
|
102
|
+
def standard_option(name, hash_key)
|
103
|
+
[Types::Standard.new(name.to_s, values[hash_key])]
|
104
104
|
end
|
105
105
|
|
106
|
-
def override_option(
|
107
|
-
standard_option(
|
106
|
+
def override_option(name)
|
107
|
+
standard_option(name, OVERRIDE_OPTIONS[name.as_key])
|
108
108
|
end
|
109
109
|
|
110
|
-
def plural_options(
|
111
|
-
standard_option(
|
112
|
-
standard_option(
|
110
|
+
def plural_options(name)
|
111
|
+
standard_option(name.to_s, name.as_key) +
|
112
|
+
standard_option(name.to_s, name.as_plural_key)
|
113
113
|
end
|
114
114
|
end
|
115
115
|
end
|
@@ -1,12 +1,16 @@
|
|
1
1
|
module RubyTerraform
|
2
2
|
module Options
|
3
|
-
class
|
4
|
-
def initialize(
|
5
|
-
@
|
3
|
+
class Name
|
4
|
+
def initialize(name)
|
5
|
+
@name = name
|
6
|
+
end
|
7
|
+
|
8
|
+
def without_prefix
|
9
|
+
@name[0] == '-' ? @name[1..] : @name
|
6
10
|
end
|
7
11
|
|
8
12
|
def to_s
|
9
|
-
"-#{
|
13
|
+
"-#{without_prefix}"
|
10
14
|
end
|
11
15
|
|
12
16
|
def as_key
|
@@ -31,10 +35,8 @@ module RubyTerraform
|
|
31
35
|
|
32
36
|
private
|
33
37
|
|
34
|
-
attr_reader :switch_without_prefix
|
35
|
-
|
36
38
|
def snake_case
|
37
|
-
|
39
|
+
without_prefix.gsub('-', '_')
|
38
40
|
end
|
39
41
|
end
|
40
42
|
end
|
@@ -0,0 +1,24 @@
|
|
1
|
+
module RubyTerraform
|
2
|
+
module Options
|
3
|
+
module Types
|
4
|
+
class Base
|
5
|
+
def initialize(name, value)
|
6
|
+
@name = name
|
7
|
+
coerce_value(value)
|
8
|
+
end
|
9
|
+
|
10
|
+
def apply(_builder)
|
11
|
+
raise 'not implemented'
|
12
|
+
end
|
13
|
+
|
14
|
+
private
|
15
|
+
|
16
|
+
attr_reader :name, :value
|
17
|
+
|
18
|
+
def coerce_value(value)
|
19
|
+
@value = value
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
@@ -0,0 +1,16 @@
|
|
1
|
+
require_relative 'base'
|
2
|
+
require_relative '../values/boolean'
|
3
|
+
|
4
|
+
module RubyTerraform
|
5
|
+
module Options
|
6
|
+
module Types
|
7
|
+
class Boolean < Base
|
8
|
+
include Values::Boolean
|
9
|
+
|
10
|
+
def apply(builder)
|
11
|
+
builder.with_option(name, value)
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
16
|
+
end
|
@@ -0,0 +1,16 @@
|
|
1
|
+
require_relative 'base'
|
2
|
+
require_relative '../values/boolean'
|
3
|
+
|
4
|
+
module RubyTerraform
|
5
|
+
module Options
|
6
|
+
module Types
|
7
|
+
class Flag < Base
|
8
|
+
include Values::Boolean
|
9
|
+
|
10
|
+
def apply(builder)
|
11
|
+
value ? builder.with_flag(name) : builder
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
16
|
+
end
|
@@ -0,0 +1,41 @@
|
|
1
|
+
require 'json'
|
2
|
+
|
3
|
+
require_relative 'base'
|
4
|
+
|
5
|
+
module RubyTerraform
|
6
|
+
module Options
|
7
|
+
module Types
|
8
|
+
class Standard < Base
|
9
|
+
def apply(builder)
|
10
|
+
if value.respond_to?(:keys)
|
11
|
+
apply_hash(builder)
|
12
|
+
elsif value.respond_to?(:each)
|
13
|
+
apply_array(builder)
|
14
|
+
else
|
15
|
+
builder.with_option(name, value)
|
16
|
+
end
|
17
|
+
end
|
18
|
+
|
19
|
+
private
|
20
|
+
|
21
|
+
def apply_hash(builder)
|
22
|
+
builder.with_repeated_option(
|
23
|
+
name,
|
24
|
+
value.map do |hash_key, hash_value|
|
25
|
+
"'#{hash_key}=#{as_string(hash_value)}'"
|
26
|
+
end,
|
27
|
+
separator: ' '
|
28
|
+
)
|
29
|
+
end
|
30
|
+
|
31
|
+
def apply_array(builder)
|
32
|
+
builder.with_repeated_option(name, value)
|
33
|
+
end
|
34
|
+
|
35
|
+
def as_string(value)
|
36
|
+
value.is_a?(String) ? value : JSON.generate(value)
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
40
|
+
end
|
41
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ruby-terraform
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.65.0.pre.
|
4
|
+
version: 0.65.0.pre.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Toby Clemson
|
@@ -256,12 +256,13 @@ files:
|
|
256
256
|
- lib/ruby_terraform/commands/workspace.rb
|
257
257
|
- lib/ruby_terraform/errors.rb
|
258
258
|
- lib/ruby_terraform/errors/execution_error.rb
|
259
|
-
- lib/ruby_terraform/options
|
260
|
-
- lib/ruby_terraform/options/boolean.rb
|
259
|
+
- lib/ruby_terraform/options.rb
|
261
260
|
- lib/ruby_terraform/options/factory.rb
|
262
|
-
- lib/ruby_terraform/options/
|
263
|
-
- lib/ruby_terraform/options/
|
264
|
-
- lib/ruby_terraform/options/
|
261
|
+
- lib/ruby_terraform/options/name.rb
|
262
|
+
- lib/ruby_terraform/options/types/base.rb
|
263
|
+
- lib/ruby_terraform/options/types/boolean.rb
|
264
|
+
- lib/ruby_terraform/options/types/flag.rb
|
265
|
+
- lib/ruby_terraform/options/types/standard.rb
|
265
266
|
- lib/ruby_terraform/options/values/boolean.rb
|
266
267
|
- lib/ruby_terraform/output.rb
|
267
268
|
- lib/ruby_terraform/version.rb
|
@@ -1,22 +0,0 @@
|
|
1
|
-
module RubyTerraform
|
2
|
-
module Options
|
3
|
-
class Base
|
4
|
-
def initialize(switch, value)
|
5
|
-
@switch = switch
|
6
|
-
coerce_value(value)
|
7
|
-
end
|
8
|
-
|
9
|
-
def apply(_builder)
|
10
|
-
raise 'not implemented'
|
11
|
-
end
|
12
|
-
|
13
|
-
private
|
14
|
-
|
15
|
-
attr_reader :switch, :value
|
16
|
-
|
17
|
-
def coerce_value(value)
|
18
|
-
@value = value
|
19
|
-
end
|
20
|
-
end
|
21
|
-
end
|
22
|
-
end
|
@@ -1,39 +0,0 @@
|
|
1
|
-
require 'json'
|
2
|
-
|
3
|
-
require_relative 'base'
|
4
|
-
|
5
|
-
module RubyTerraform
|
6
|
-
module Options
|
7
|
-
class Standard < Base
|
8
|
-
def apply(builder)
|
9
|
-
if value.respond_to?(:keys)
|
10
|
-
apply_hash(builder)
|
11
|
-
elsif value.respond_to?(:each)
|
12
|
-
apply_array(builder)
|
13
|
-
else
|
14
|
-
builder.with_option(switch, value)
|
15
|
-
end
|
16
|
-
end
|
17
|
-
|
18
|
-
private
|
19
|
-
|
20
|
-
def apply_hash(builder)
|
21
|
-
builder.with_repeated_option(
|
22
|
-
switch,
|
23
|
-
value.map do |hash_key, hash_value|
|
24
|
-
"'#{hash_key}=#{as_string(hash_value)}'"
|
25
|
-
end,
|
26
|
-
separator: ' '
|
27
|
-
)
|
28
|
-
end
|
29
|
-
|
30
|
-
def apply_array(builder)
|
31
|
-
builder.with_repeated_option(switch, value)
|
32
|
-
end
|
33
|
-
|
34
|
-
def as_string(value)
|
35
|
-
value.is_a?(String) ? value : JSON.generate(value)
|
36
|
-
end
|
37
|
-
end
|
38
|
-
end
|
39
|
-
end
|